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!

Executing multiple statements in Query Window

Status
Not open for further replies.

DonS100

Programmer
Dec 4, 2001
104
US
Hello, how would you execute multiple queries at one in the Query Window. When I run the two lines below I get the following message. syntax error (missing operator) in query expression 'staffcode = 'gmz' update staffcode set lastname = 'Test' where staffcode = 'gmz''

update staffcode set lastname = 'Test' where staffcode = 'gmz'
update staffcode set lastname = 'Test' where staffcode = 'gmz'

Thanks

Don
 
Why would you execute twice the same update query ?

Hope This Helps, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ222-2244
 
You don't need a fresh query for each line you're updating if it is a common sequence.

If you are trying to do several different types of update then create individual queries and run them as a batch eg with a macro.

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top