Script functions reference > Script functions in alphabetical order > L > LdapSort

LdapSort
Syntax
LdapSort(resultId, sortType, attrName_1[,attrName_2...attrNameN]);
resultId
sortType
N – Numeric sort
S – String sort
C – String collation
A – Ascending (Default)
D – Descending
If you specify sort type S you can add the following to the string:
attrNameN
Description
Sorts entries in a result set based on one or more entry attributes. The sorting is based on attrName_1 first, then attrName_2, and so on.
Returns
1
-1
Example
// Sort the search result by string (case insensitive) in ascending // order using the "common name" ("cn") attribute.
ldapsort($myResultId, "SAI", "cn");
OpenText StreamServe 5.6 Updated: 2013-03-01