Sort of list within list within list

Discussion in 'Access Forms Coding' started by H. Martins, Apr 9, 2013.

  1. H. Martins

    H. Martins Guest

    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. Martins, Apr 9, 2013
    #1
    1. Advertisements

  2. 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
    news:...

    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
     
    Douglas J Steele, Apr 9, 2013
    #2
    1. Advertisements

  3. H. Martins

    H. Martins Guest

    Hi Douglas,

    Thank you.

    But, how do I do this triple record listing the way as the example shows?
     
    H. Martins, Apr 10, 2013
    #3
  4. 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
    news:...

    Hi Douglas,

    Thank you.

    But, how do I do this triple record listing the way as the example shows?
     
    Douglas J Steele, Apr 10, 2013
    #4
    1. Advertisements

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 (here). After that, you can post your question and our members will help you out.
Similar Threads
  1. Michel Peeters

    list box made by AddItems - how to sort?

    Michel Peeters, Nov 11, 2003, in forum: Access Forms Coding
    Replies:
    7
    Views:
    105
    Cheryl Fischer
    Nov 13, 2003
  2. MSD

    sort fields in a list box

    MSD, Feb 11, 2004, in forum: Access Forms Coding
    Replies:
    1
    Views:
    58
    Guest
    Feb 11, 2004
  3. Frank's Newsgroups

    AlpahNumeric text field sort within a grouped report.

    Frank's Newsgroups, Apr 3, 2004, in forum: Access Forms Coding
    Replies:
    2
    Views:
    107
    Frank's Newsgroups
    Apr 4, 2004
  4. Dap

    loop within a loop, sort of

    Dap, Apr 9, 2004, in forum: Access Forms Coding
    Replies:
    1
    Views:
    228
    Bryan Reich [MSFT]
    Apr 12, 2004
  5. Phil Freihofner

    how sort a subform (within transaction)

    Phil Freihofner, May 14, 2004, in forum: Access Forms Coding
    Replies:
    0
    Views:
    86
    Phil Freihofner
    May 14, 2004
  6. John

    unbound list box sort

    John, Jul 9, 2004, in forum: Access Forms Coding
    Replies:
    3
    Views:
    108
  7. Sam

    Sort List box

    Sam, Jan 6, 2006, in forum: Access Forms Coding
    Replies:
    4
    Views:
    65
  8. Wes

    Sort form and remove sort

    Wes, Oct 31, 2007, in forum: Access Forms Coding
    Replies:
    2
    Views:
    140
Loading...