You can append the Ns parameter to an EQL request to sort the returned record set by a property of the records.

To do so, use the following syntax:


The Ns parameter specifies the property or dimension by which to sort the records, and an optional list of directions in which to sort. For example, this query:

Nrs=collection()/records[book_authorref = collection()
	/records[author_nationality = "american"]

returns all books written by American authors and sorts the records by the year in which the book was written (the book_year property). You can also add the optional order parameter to Ns to control the order in which the property is sorted (0 is for an ascending sort while 1 is descending). The default sort order for a property is ascending. For example, the above query returns the records in ascending order (from the earliest year to the latest), while the following Ns syntax uses a descending sort order:


Copyright © Legal Notices