Macro Using Update of Queries

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I have a small application that links to SQL Server to update a spreadsheet
that resides in Access.

I have 36 separete update statements that are called by one Macro script.
The first script Turns off all the warnings and then it follows up with 35
scripts and each one calls an Update Query. My problem is that if I run the
query it works fine (asynchronosuly) and then on my Macro it runs good some
of the time and then some of the time it doesn't run good.

Is there supposed to be some "wait" that I should put since of the great
amount of queries that my script calls? and then how does the script know
that the last call has occurred and it is ready for the next call (update
query) to be executed?

Can someone shed light on this for me? It's driving me nuts, especially if
the updates work good and then they don't update at all. I checked the query
statements and they are syntaxed correctly, but the updates don't ocurr
sometimes.

Also, some of the info, it reads from is from SQL and it does an INSERT to a
spreadsheet in my Access database. Is there some lag time there, do you
think?

Thanks in advance for any guidance you may provide me since I am to the last
resort on this.
 
I have to also, add I researched this topic and I saw on another post that
there is no wait method to allow the completion of one update before another
begins.

Any suggestions, anbody?
 
Ae,

If you don't get the help you need from these newsgroups, there are a
number of possible explanations.

1. No-one who reads your question knows the answer.
2. No-one who reads your question can understand your question.
3. Your question is too vague and/or confused.
4. Your question is to an inappropriate newsgroup.

The remedy is generally to repost and try again to explain yourself. In
your case, you could start by mentioning what actions you are using in
your macro, show an example of the SQL view of your Update Queries,
explain the meaning of "it doesn't run good", and clarify your
terminology (for example, there is no such thing as a spreadsheet in
Access).

I must say that running 35 Update Queries on the one table is extremely
unusual, and it is almost certain that there is an easier way to achieve
your purpose.
 
It should also be pointed out that Microsoft isn't directly involved in
these newsgroups, so you can't really blame them for the lack of an answer.
 
Back
Top