Sort of list within list within list

H

H. Martins

Hi.

I need some hint (Access 2003).

Simplifying, I have a database that has a table for cities, a table for companies and, as expected, a table for employees.

Tables are related as: cities has companies, companies have employes.

How do I do a list of cities / companies / employees as:

CityX
Company1
EmployeeA
EmployeeB
Company2
EmployeeC
EmployeeD
EmployeeE
CityY
Company3
EmployeeF
Company4
EmployeeG
EmployeeH
EmployeeI
Company5
EmployeeJ
EmployeeK
EmployeeL


Should I use a Report, a Form?

Thanks
Martins
 
D

Douglas J Steele

Depends what you want to do with it. If you want to print it, you should use
a report. If you want the user to interact with it, you should use a form.

If you're using a form, be aware that queries that join 3 tables often are
not updatable.

If you're using a report, remember that Access does not respect the sort
order applied to the query: you must use the Grouping and Sorting dialog for
the report.

"H. Martins" wrote in message

Hi.

I need some hint (Access 2003).

Simplifying, I have a database that has a table for cities, a table for
companies and, as expected, a table for employees.

Tables are related as: cities has companies, companies have employes.

How do I do a list of cities / companies / employees as:

CityX
Company1
EmployeeA
EmployeeB
Company2
EmployeeC
EmployeeD
EmployeeE
CityY
Company3
EmployeeF
Company4
EmployeeG
EmployeeH
EmployeeI
Company5
EmployeeJ
EmployeeK
EmployeeL


Should I use a Report, a Form?

Thanks
Martins
 
H

H. Martins

Hi Douglas,

Thank you.

But, how do I do this triple record listing the way as the example shows?
 
D

Douglas J Steele

In a report, you'd Group on City and then on Company and you'd sort on
Employee.

Add GroupHeaders for the two groups you created: put the City in the first
group header and the company in the second one.

"H. Martins" wrote in message

Hi Douglas,

Thank you.

But, how do I do this triple record listing the way as the example shows?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Top