Query Help

merciless32

Registered User.
Local time
Today, 21:01
Joined
Mar 4, 2002
Messages
48
OK,
I have 15 different tables and forms in my databse. I would like to build ONE query that will be attached to a button that filters the records according to a status field. This button would run a query that will display all records with an 'X' status. I would like to be able to put this button on every form and have it sort whatever form/table is currently active instead of building a query for every single form and table...
 
Well so long as your forms are built on a query and that query has the status field then you can:

1) Insert a combo box with the record source showing the status.
2) On_Change Event of the combo me.frmName.requery
3) In the underlying query reference the combo box in the status field criteria.
 
I wonder if you went to school with a former boss who once asked me if instead of writting 10 programs to perform 10 functions, I wrote 5 programs to perform 2 functions each, would it take less time.

It doesn't make any sense to try to write a single query rather than one for each table. Of course if all 15 tables are identical, you have a much bigger design problem. If the tables are not identical, there would not be any commonality so there could not be a common query.
 
Pat,

The same thoughts crossed my mind and I guess instead of offering advice on the initial problem I should look at the bigger picture, like your good self!

I agree that the design looks to be the problem.
 

Users who are viewing this thread

Back
Top Bottom