Print

SortTable

This function will sort specified table with values from specified fields.

Syntax

SortTable("tableName","fieldName",["fieldName"]);

Function arguments

  • tableName – (String) Table name
  • fieldName – (String) The name of the field to sort. You can pass as many fields as you want. The sort direction asc | desc can be specified after the field name (defaults asc).

Return value

This function returns Boolean.
This function returns true if any rows changes its index, otherwise returns false

Examples

Example 1:
Sort Orders table by values in Type column

SortTable("Orders","Type");

Example 2:
Sort Orders table by values in Type and Symbol columns.

SortTable("Orders","Type","Symbol");
Czy artykuł był pomocny?
0.5 na 5 gwiazdek

1 rating

5 Stars 0%
4 Stars 0%
3 Stars 0%
2 Stars 0%
1 Stars 100%
5
How can we improve this article?
How Can We Improve This Article?