TOC : Script API > JavaScript > JavaScript API > Component > ReportTemplate > Method >

 

SetDataSetSorting

<< Click to Display Table of Contents >>

Navigation:  »No topics above this level«

TOC : Script API > JavaScript > JavaScript API > Component > ReportTemplate > Method >

 

SetDataSetSorting

 

 

Sort the local data of a viewer.

 

 

 

Prototype :

 

void SetDataSetSorting

(

        string DataSetPath,

        string SortInformation

)

 

 

 

Arguments :

 

DataSetPath

DataSet Path in the form of "ODI name.dataset name"

SortInformation

Set by form of "field_name sort_order"

Use comma(,) to separate between multiple fields

 

 

 

Reference :

 

SetDataSetSorting does not retrieve data from server and sort only the local data of the viewer.

 

Types of sort orders can be "ASC" or "DESC" and  is not case sensitive.  The default is "ASC".

 

 

 

Example :

 

//ODI name : Sample, dataset name : Orders

  ReportTemplate.SetDataSetSorting("Sample.Orders", "Region ASC, Price DESC");

 

 

 

Available Events :

 

OnStartUp