need a function to sort a cdt by a date/time field. Is there such a function to

need a function to sort a cdt by a date/time field. Is there such a function to do that? ...

OriginalPostID-88128

OriginalPostID-88128

  Discussion posts and replies are publicly visible

Parents
  • The following example shows how you can take your pagingInfoObject that has been returned by your query rule and sorts on the field called "createdOn":
    Name: getNotesForCaseIdSortedByCreationTs
    Rule input 1: caseId (Number (Integer))
    Rule input 2: pagingInfo (Any Type)
    Definition:
    =if(isnull(ri!pagingInfo.sort),
    getNotesForCaseId(ri!caseId,
    {startIndex: ri!pagingInfo.startIndex,
    batchSize: ri!pagingInfo.batchSize,
    sort: {field:"createdOn", ascending:false()}
    }
    ),
    getNotesForCaseId(ri!caseId, ri!pagingInfo)
    )

    You can also choose the sort the result returned by your query rule. Please see forum.appian.com/.../Rules for more information
Reply
  • The following example shows how you can take your pagingInfoObject that has been returned by your query rule and sorts on the field called "createdOn":
    Name: getNotesForCaseIdSortedByCreationTs
    Rule input 1: caseId (Number (Integer))
    Rule input 2: pagingInfo (Any Type)
    Definition:
    =if(isnull(ri!pagingInfo.sort),
    getNotesForCaseId(ri!caseId,
    {startIndex: ri!pagingInfo.startIndex,
    batchSize: ri!pagingInfo.batchSize,
    sort: {field:"createdOn", ascending:false()}
    }
    ),
    getNotesForCaseId(ri!caseId, ri!pagingInfo)
    )

    You can also choose the sort the result returned by your query rule. Please see forum.appian.com/.../Rules for more information
Children
No Data