how to print query's sql view

D

djh

In Access97 how can I print the SQL code for a query. In the Design of the
query, I go to SQL view and all of the code is highlighted, but I do not see
any way to print it directly from there. I can copy and paste it elsewhere
for printing, but I would think it can be done from within the Access product.
 
O

Ofer

Try this, to print the SQL of a query

application.CurrentDb.QueryDefs("QueryName").SQL
 
F

fredg

In Access97 how can I print the SQL code for a query. In the Design of the
query, I go to SQL view and all of the code is highlighted, but I do not see
any way to print it directly from there. I can copy and paste it elsewhere
for printing, but I would think it can be done from within the Access product.

Tools + Analyze + Documenter
Select the query and then Options. Unselect everything you can except
SQL.
 
Top