Professional > Table scripting > Table presentation > Sorting tables
 
Sorting tables
This section provides information on sorting, with examples of sorting basic and more complex tables.
Notes and general limitations
If there is more than one item of cell contents, the first item is always used for the sort.
By default, values are sorted in descending order.
Sorting rows that contain cumulative column percentages or columns that contain cumulative row percentages is not recommended, as the reordered percentage values do not give meaningful results.
Axes are not sorted if they contain a combination of nesting and concatenation and UNICOM Intelligence Professional does not issue a message to alert you to this.
You cannot use an element that is inside a net to sort the other axis of the table.
You cannot sort an axis that contains net elements in an outer nest level. Any sorting that would apply to the axis is ignored.
There are a number of special rules that apply when sorting axes that contain special elements. See Sorting special elements.
Note The examples in this section are available in sample mrScriptBasic files called MyFirstSortedTable.mrs and SortedTables.mrs. These example scripts are based on the Museum sample data set. See Running the sample table scripts for more information.
See also
Introduction to sorting tables
Sorting nested and concatenated tables
Sorting net elements
Sorting special elements
Sorting grid tables
Table presentation