Problem with SQL - INSERT INTO

Results 1 to 2 of 2

Thread: Problem with SQL - INSERT INTO

  1. #1
    Join Date
    Dec 1969
    Posts
    21

    Default Problem with SQL - INSERT INTO

    I have this simple ASP for testing <BR>&#062;&#060;% <BR>&#062;Set objConnection = Server.CreateObject("ADODB.Connection" )<BR>&#062;objConnection.Open "www_nt-tech_iol_cz"<BR>&#062;Set objRecordset = Server.CreateObject("ADODB.Recordset" )<BR>&#062;objRecordse.Open " INSERT INTO Tabulka1.text VALUES " " ; ", &#062;objConnection, 3, 3<BR>%&#062;<BR><BR>But when I tried it i recived this error, can anyone help me where is the problem?<BR><BR>&#062;Microsoft VBScript compilation error &#039 800a0401&#039 &#062;<BR>&#062;Expected end of statement <BR>&#062;/databaze/databaze.asp, line 15 <BR>&#062;objRecordse.Open " INSERT INTO Tabulka1.text VALUES " " ; ", &#062;objConnection, 3, 3<BR>&#062;------------------------------------------------------^<BR><BR>

  2. #2
    Jairo Guest

    Default RE: Problem with SQL - INSERT INTO

    Try this syntax instead - note the quotes:<BR><BR>objRecordset.Open " INSERT INTO " & Tabulka1.text & " VALUES ...<BR><BR>HTH,<BR>Jairo<BR>http://www.citywebarchitects.com

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •