Thread: Can Shrink
View Single Post
  #10  
Old February 17th, 2006, 06:26 PM posted to microsoft.public.access
external usenet poster
 
Posts: n/a
Default Can Shrink

Yep, you do enter this in SQL view. The first thing then is to confirm that
it returns the correct rows by switching to datasheet view. If you are happy
that it does then the question is what else do you need to show in the
report. Say you want to show vendors' names from a Vendors table which the
Vendor Number field in tblGrant Completion-March references, then you'd add
the vendors table to the query and join it to tblGrant Completion-March on
the Vendor Number fields. I'd normally do this by simply typing in some
extra SQL, but you can also do it by switching to design view then adding the
table and joining it to tblGrant Completion-March visually in the usual way.
You can then drag whatever other fields you need into blank columns the query
design grid. Once you are satisfied that you have all the necessary fields
for the report save the query under any suitable name.

As far as the report is concerned you just enter the query name as its
RecordSource property in the report's properties sheet. As you no longer
need a subreport you can discard that. In the report's sorting and grouping
dialogue you'd group on either the Vendor Number or a vendor Name as the
first group level, providing the names are unique, and give it a group
header. The advantage of grouping on the name is that the report will show
the vendors in alphabetical order.

Fields such as Vendor name relating to the Vendor go in the group header so
you only see them once in the report. The Months go in the detail so that
they are listed individually.

Ken Sheridan
Stafford, England

"Chey" wrote:

No so I understand this righ this code goes in SQL View under the query right?
Then how do I do the other query it askes me to save the SQL query then can
I build another query to display on my report?