Finding which queries use specific control from the main form (4 Viewers)

A point worth making IMO in respect to working with control references in queries:
• Don't put control references in queries.

Control names and anything along the path that references them are ...
• subject to change without notice, and
• not subject to compiler scrutiny.
You might as well put a sharp stick somewhere well travelled, somewhere dark, and right at eye level. Or sprinkle glass on the bathroom floor just before bed.

A control is your UI. A query is your database. If you have zero distance between them and anything goes wrong, you are immediately out of runway.
 
I must admit I never liked hardcoding form references in queries.
I would prefer to use TempVars() and populate them with whatever was needed.
 
A point worth making IMO in respect to working with control references in queries:
• Don't put control references in queries.

Agreed.
However I thought the OP wanted to analyze an old database to identify existing references to a specific form in queries in order to then modify the query SQL
 

Users who are viewing this thread

Back
Top Bottom