Results 1 to 4 of 4
  1. #1
    Join Date
    Apr 2004
    Location
    ny, ny
    Posts
    224

    Unanswered: ordering for more than one criteria

    WOlist = "SELECT [WorkType].WorkTypeDescription as [WorkType], Workorders.DateReceived as [Date In], Workorders.TimeIn as [Time In]
    "FROM (Workorders LEFT JOIN [WorkType] ON Workorders.WorkType = [WorkType].WorkTypeID) LEFT JOIN WorkStatus ON Workorders.WorkStatus = WorkStatus.WorkStatusID ORDER BY Workorders.DateReceived DESC and workorders.timein desc;"

    I need to order by datereceived and timein in desc

    what is the syntax for that

    thank you

  2. #2
    Join Date
    Sep 2003
    Location
    The extremely Royal borough of Kensington, London
    Posts
    778
    ORDER BY column1, column2 DESC
    Bessie Braddock: Winston, you are drunk!
    Churchill: And Madam, you are ugly. And tomorrow, I'll be sober, and you will still be ugly.

  3. #3
    Join Date
    Apr 2004
    Location
    ny, ny
    Posts
    224
    is it column1, column2 desc
    or workorders.datereceived, workorders.timein desc

    neither wok
    column1, column2 is not recognized
    and the latter doesnt give the result

    i need the info displayed first sorted by datereceived desc and then timein desc

  4. #4
    Join Date
    Sep 2003
    Location
    The extremely Royal borough of Kensington, London
    Posts
    778
    ORDER BY Workorders.DateReceived, workorders.timein DESC
    Bessie Braddock: Winston, you are drunk!
    Churchill: And Madam, you are ugly. And tomorrow, I'll be sober, and you will still be ugly.

Posting Permissions

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