I have a table in an exact form and I want to sort by in order of newest to oldest date. I'm using options=nvw.ned.phd.nfg.sortorder-A^slist=6");~ with variable 6 being my date field.

  • 0
  • 1
  • Question
  • Updated 6 years ago
  • Answered
Photo of Anne

Anne

  • 100 Points 100 badge 2x thumb

Posted 6 years ago

  • 0
  • 1
Photo of Keith

Keith, Champion

  • 1,126 Points 1k badge 2x thumb
Not sure if this is the answer but give it a try and see if it works...
change slist=6 to slist=D6
Photo of Anne

Anne

  • 100 Points 100 badge 2x thumb
This worked perfectly.  Thank you - I was changing the sortorder-"A" to a "D" thinking this meant ascending/descending.
Photo of Keith

Keith, Champion

  • 1,126 Points 1k badge 2x thumb
You are correct with the -A and -D being ascending and descending.  The D in front of the 6 is needed because the API is a little funny when it comes to date fields.  You need to tell the API that field 6 is a DATE field for it to treat it properly.