Problem in executing consequent queries

  • Thread starter Thread starter muster
  • Start date Start date
M

muster

I ran in a problem when executing series of queries.

Dim Cnxn As New ADODB.Connection
Cnxn.Open CurrentProject.Connection
Dim lngRA As Long, lngOptions As Long
lngOptions = adCmdStoredProc

Cnxn.Execute "qryA", lngRA, lngOptions
Cnxn.Execute "qryB", lngRA, lngOptions
Cnxn.Execute "qryC", lngRA, lngOptions
Cnxn.Execute "qryD", lngRA, lngOptions

aryA would generate tblA, qryB use tblA. qryB would give an error
saying "tblA not found, ...". But when I F5 it runs ok. Seemingly
something not been refreshed.

Any method to refresh? Option prameters? Any other hints?

Thank you,
Muster
 

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

Back
Top