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 SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

SQL query error

Status
Not open for further replies.

supermaestro

Programmer
Dec 18, 2002
15
0
0
GB
Can somebody please tell me why i'm getting a missing semi colon error 3137?


CurrentDb.Execute "insert into transactions ([transactions].[Last Transaction],[transactions].[Transaction Date],[transactions].[Transaction Notes],[transactions].[Next Action Date],[transactions].[Next Transaction]) values ('Mailshot','" & Now() & "','" & Transaction_Notes & "','" & Next_Action_Date & "','Call') WHERE contacts.[Contact ID] = transactions.[Contact ID];"

cheers
 
Shouldn't the semi colon be outside the " ?
WHERE contacts.[Contact ID] = transactions.[Contact ID]";
and not
WHERE contacts.[Contact ID] = transactions.[Contact ID];"

 
Hmmm, what is the where clause doing in an insert statement?

Maybe it's an update you are after.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top