Results 1 to 2 of 2
  1. #1
    accessLearn is offline Novice
    Windows 7 64bit Access 2003
    Join Date
    Jul 2015
    Posts
    11

    Sorting based on IDs

    I have built a database in access where there is a date of shipment and the id of the product is generated by mm+yy-001 (incrementing 1) but the issue is the id was not being incrementing by 1 till 2015
    So if the shipment was received in December 2014, the unique id would be 1214-001
    and for Jan 2015, then id is 0115-001 , Feb 0215—01, March 0315-001 but from April 2015 the id has been incrementing by 1 , so march id is 0415-002 and May is 0515-003 and so on.
    Now when I generate the report, I get all the 2015 records first and then December 2014 but I want to display December 2014 record first and then Jan 2015, Feb 2015 etc.
    So the Ids are
    1214-001
    0115-001
    0215-001
    0315-001
    0415-002
    0515-003
    0615-004
    0715-005
    0815-006
    0915-007
    1015-008
    1115-009
    And I want to display them in the same order.

    How can I do that?



    Thanks,
    Blyzz

  2. #2
    RuralGuy's Avatar
    RuralGuy is offline Administrator
    Windows 7 64bit Access 2013
    Join Date
    Mar 2007
    Location
    8300' in the Colorado Rocky Mountains
    Posts
    12,917
    How about creating a query that adds another field to sort on? That field could use one of the Date functions (DatePart,DateSerial,DateValue) to create an actual date from the ID field.

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Replies: 7
    Last Post: 06-11-2015, 10:10 AM
  2. Sorting a Report field based on its value
    By mindbender in forum Reports
    Replies: 5
    Last Post: 09-30-2014, 01:40 PM
  3. Sorting Report Based off of a Combo Box in a Form
    By datadude60 in forum Reports
    Replies: 4
    Last Post: 04-30-2012, 10:38 AM
  4. Replies: 11
    Last Post: 01-12-2012, 07:55 PM
  5. Incorrect Binary-based ASCII sorting in tables
    By ajetrumpet in forum Programming
    Replies: 2
    Last Post: 11-24-2011, 06:00 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums