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

run multiple queries in order with same parameter 1

Status
Not open for further replies.

mgargUWBC

Instructor
May 22, 2003
9
US
Hi!

I've got a situtation and I need some advice on. I have a "set" of 15 delete queries that need to be run in a specific order. Each of the delete queries requires one parameter and it is the same parameter for each query (an ending date).

I can run the queries in order, but each query asks for the ending date. How do I run the queries in order without asking the user for the ending date 15 times? Is there a way to run a query from VB and send it a value for the parameter?

TIA,
Michelle
 
1) You may play with the Parameters collection of the QueryDef object
2) You may have a form with a TextBox for the ending date and modify your 15 delete queries to replace the [Ending date] parameter by [Forms]![yourNewForm]![txtEndingDate]
and then you may execute the 15 queries without asking the user each time, provided the form is open.

Hope This Helps, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ222-2244
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top