L
Lester Lane
Hello,
Can someone please help with this issue I have in wanting to reuse a
query that is the source for a subform that is used across my database
by many main forms. The query is itself linked to a grouped query
(Max of date) so it potentially has many records behind it. It
basically retrieves the latest price of stock. I want to pass a
parameter to this query (StockID) to a) speed up Access loading the
form (because I believe that unless you have a MDE it "tests" your
query on loading) and b) keep my queries to one per job.
Should I pass the parameter to the final query (a select query) or the
embedded grouped query? I.e. does the select query "pass" the
parameter by use of the join it has? It's been a while since my SQL
course!
If I change the main form combo to choose another stock, then this
subform must of course requery and pass the new parameter. It does
work with no parameter and using LinkFields for the subform but it is
slow. If I use a criteria of Forms!frmForm!field style then this will
only work for one form. Pointers most welcome!
Using Access 2003 on XP.
Can someone please help with this issue I have in wanting to reuse a
query that is the source for a subform that is used across my database
by many main forms. The query is itself linked to a grouped query
(Max of date) so it potentially has many records behind it. It
basically retrieves the latest price of stock. I want to pass a
parameter to this query (StockID) to a) speed up Access loading the
form (because I believe that unless you have a MDE it "tests" your
query on loading) and b) keep my queries to one per job.
Should I pass the parameter to the final query (a select query) or the
embedded grouped query? I.e. does the select query "pass" the
parameter by use of the join it has? It's been a while since my SQL
course!
If I change the main form combo to choose another stock, then this
subform must of course requery and pass the new parameter. It does
work with no parameter and using LinkFields for the subform but it is
slow. If I use a criteria of Forms!frmForm!field style then this will
only work for one form. Pointers most welcome!
Using Access 2003 on XP.