Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Syntax error in update query vb 6

Status
Not open for further replies.

case81

Programmer
Jan 10, 2002
23
IE
hey all,

im getting a syntax error for this query:

sqlupdate = "UPDATE teams SET day='yes' WHERE tid=" & teamid
rsTeams.open sqlstr,dbcon

any ideas as to what could be causing this? im confused.
Thanks
 
Did you try putting ur field names in brackets? Your field 'day' may be a reserved word somewhere...

sqlupdate = "UPDATE teams SET [day]='yes' WHERE [tid]=" & teamid

Also, I'm assuming 'tid' is a numeric field, not text cuz you left the quotes off.

HTH!

~Mike
Any man willing to sacrifice liberty for security deserves neither liberty nor security.

-Ben Franklin
 
Thanks Mike,

That didnt work but i've found a work around, thanks for replying though :)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top