Display query ID in report

  • Thread starter Thread starter mnoll
  • Start date Start date
M

mnoll

Is there a way to display either the query sql statement or query name as a
field in a report?
 
Is there a way to display either the query sql statement or query name as a
field in a report?

The query is the report's record source?
Using an unbound text control:

=[RecordSource]

will get the name of the query or the Record source SQL if there is no
named query.
 
You could use a calculated field like this --
My_Query_Name: "The query is named XyZ_Code"
 
This worked like a charm, thanks I have needed this for a while and just
happened to stumble across your repoonce.... I used this:

="Data Source"& " " & [RecordSource]

Simple but great! thanks

Duane Hookom said:
You can try a text box with a control source of:
=[RecordSource]

--
Duane Hookom
Microsoft Access MVP


mnoll said:
Is there a way to display either the query sql statement or query name as a
field in a report?
 
thank you so much for the assistance.... just what I needed.
--
mn


Duane Hookom said:
You can try a text box with a control source of:
=[RecordSource]

--
Duane Hookom
Microsoft Access MVP


mnoll said:
Is there a way to display either the query sql statement or query name as a
field in a report?
 
Back
Top