Append & Update Query???

D

Douglas J. Steele

Before the queries are run, set SetWarnings False, then SetWarnings True
after you've run.

BTW, it's possible to do update and append in a single query.

UPDATE NewData LEFT JOIN ExistingData
ON [NewData].[ID] = [ExistingData].[ID]
SET [ExistingData].[ID] = [NewData].[ID],
[ExistingData].[Field1] = [NewData].[Field1],
[ExistingData].[Field2] = [NewData].[Field2], ... (need to do this for each
field)

This is discussed in http://support.microsoft.com/?id=127977
 
G

Graham Feeley

Hi hoping someone may enlighten me.
Got a form which has a Command button which runs a macro which in turn runs
2 Queries one append and the other an update query.
These are working , however they both require me to hit yes twice for each
query. How can I get around this to automate it altogether by eliminating
the message box
Regards
Graham
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top