MySQL Forums
Forum List  »  Newbie

Here's my code (basically)...
Posted by: Greg Jamison
Date: August 17, 2004 12:38PM

Here's what I'm basically doing (VBScript)...


mySQL = "INSERT INTO Users " _
& "(auto,text) " _
& "VALUES " _
& "(NULL,'text'); " _
& "SELECT LAST_INSERT_ID();"
set rsTemp = conntemp.Execute(mySQL)
usrID = rsTemp(0)
call closeRS(rsTemp)


But I'm getting an error that says...

[MySQL][ODBC 3.51 Driver][mysqld-4.0.16-standard-log]You have an error in your SQL syntax. Check the manual that corresponds to your MySQL server version for the right syntax to use near '; SELECT LAST_INSERT_ID()' at line 1

Help appreciated!

Options: ReplyQuote


Subject
Written By
Posted
Here's my code (basically)...
August 17, 2004 12:38PM
August 18, 2004 12:15PM
August 19, 2004 03:42AM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.