Printing group header with empty group

  • Thread starter Thread starter Sniffer
  • Start date Start date
S

Sniffer

Hi,

is there anyway that I can still print a group header in a report when there
are no items within the group itself? I keep meeting minutes using access
and send people tasks. If there are no tasks I still want to keep the group
headings as I keep category related minutes in these sections that have no
associated tasks, i.e. things agreed and discussed during the meeting.

Thanks in advance,

Gary
 
Gary,

Change the join type in your query. Include all rows
from "group header" table and only rows where equal in
the "detail" table. This should give you a record set that
you can use and will probably work without any changes to
your report.

HTH,

Terry
 
Base the report on a query. The query will need to generate a record for
each 'group', regardless of whether it has related records or not.

Typically, you have a table of these 'groups', and a related table with the
main data. In query design view, you will see a line joining the 2 tables.
Double-click the join line. Access opens a dialog with 3 options. Choose the
one that says:
"All records from 'groups', and any matches from ..."

Verify that the query does show all groups, and the report should show them.

If you use criteria in an outer join query, it's easy to lose those records
again. More information in:
The Query Lost My Records! (Nulls)
at:
http://members.iinet.net.au/~allenbrowne/casu-02.html
 
Hello Allen,

thanks for your response. I have tried this and cant seem to get it to work.
Is there anyway that I can send my database to you so that you can have a
look at it?

Thanks again

Gary
 
Hi Gary,

We can't open everyone's databases for free, because we would spend all day
doing nothing else, and that's what we do for a living.

Try to break the problem down, so you get a simple example working, and then
build up from there.

To get you started, open the Northwind sample database, create a new query,
switch it to SQL View, and paste in this statement:

SELECT Categories.CategoryID, Categories.CategoryName,
Products.ProductID, Products.ProductName
FROM Categories LEFT JOIN Products
ON Categories.CategoryID = Products.CategoryID
ORDER BY Categories.CategoryID DESC;

Enter a new category called (say) Junk Food.
Run the query and you will see the record for junk food on the first line.
A report based on this query would work as you asked.
 
Back
Top