sort

1. Syntax:

Return Range  sort(Range source)

Description:

Sorts source according to the first column in the range and places the sorted range at the current cell.

2. Syntax:

Return Range sort(Range source, Column pivot)

Description:

Sorts source according to the pivot column in the range and places the sorted range at the current cell.

3. Syntax:

Return Range sort(Range source, Column pivot, Identifier mode)

Description:

Sorts source in reverse according to the pivot column in the range and places the sorted range at the current cell.

Options:

Identifier mode:

4. Syntax:

Return Range sort(Range source, Identifier mode)

Description:

Sorts source in reverse according to the first column in the range and places the sorted range at the current cell.

Options:

Identifier mode:

Examples:

($a1) = sort($b1:$c7)
Before:
AB C
1orange4
2apple
3532
4banana-7.2
5mango18
61341
7pear
After:
AB C
113414
2532
3apple32
4banana-7.2-7.2
5mango1818
6orange441
7pear
($b2) = sort($b1:$d10,$c,reverse)