Results 1 to 5 of 5
  1. #1
    Join Date
    Feb 2004
    Posts
    90

    Question Unanswered: Sorting a Continuous Form by Value in a Related Table

    Hi.

    I have a continuous subform that has a combo box that takes its data from another table ("Supplier Item Subcategory Description" from the "Supplier Item Subcategory" table). Each "Supplier Item Subcategory Description" has a corresponding "Sorting Number" field in its table. In my continuous for I need to sort the fields by this "Sorting Number" field, but this field isn't present in the forms data source (only the "Supplier Item Subcategory Description" is present, as previously metioned in the for of a combo box. If I create a query that adds the "Sorting Number", I cannot then add new fields the the query (so it would be useless as a new data source for the continuous form in question).

    Any ideas how I can sort the forms records by it's corresponding "Supplier Item Subcategory - Sorting Number" and be allowed to add new records to the data source?

    Thanks in advance.


  2. #2
    Join Date
    Feb 2004
    Posts
    199
    no other way unless change subform's rowsource
    what's the problem with adding fields , could you describe in details
    MDB, ADP <-> MS SQL + VBA, ADO & RDO, .NET, Oracle, Java/Jsp.

  3. #3
    Join Date
    Feb 2004
    Posts
    90
    As they say "a picture tells a thousand words" (see attachment).

    Any help?
    Attached Thumbnails Attached Thumbnails db_prob.gif  

  4. #4
    Join Date
    Sep 2003
    Location
    MI
    Posts
    3,713

    Re: Sorting a Continuous Form by Value in a Related Table

    Originally posted by Goldy
    Hi.

    I have a continuous subform that has a combo box that takes its data from another table ("Supplier Item Subcategory Description" from the "Supplier Item Subcategory" table). Each "Supplier Item Subcategory Description" has a corresponding "Sorting Number" field in its table. In my continuous for I need to sort the fields by this "Sorting Number" field, but this field isn't present in the forms data source (only the "Supplier Item Subcategory Description" is present, as previously metioned in the for of a combo box. If I create a query that adds the "Sorting Number", I cannot then add new fields the the query (so it would be useless as a new data source for the continuous form in question).

    Any ideas how I can sort the forms records by it's corresponding "Supplier Item Subcategory - Sorting Number" and be allowed to add new records to the data source?

    Thanks in advance.

    Since this is a combobox you're talking about, the combobox should have the Sorting # be the bound column (and be the column that the combobox is set to by the query) making it available to be ordered on.

  5. #5
    Join Date
    Feb 2004
    Posts
    90
    Thanks for the replies Kakha and M Owen. I've sorted it using M Owen's suggestion. My db took some redesigning though, in order to accomodate some changes needed to implement it this way (I really should plan ahead and be more methodical).

    Sorted though.

    Cheers!

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •