SheetRocks
Documentation/Formulas/UNIQUE

UNIQUE

Returns a list of unique values in a list or range.

Syntax

UNIQUE(array, [by_col], [occurs_once])

Arguments

Argument Description Required
array The range or array from which to find the unique values. Required
by_col Whether to find unique values by column (TRUE) or by row (FALSE). Optional
occurs_once Whether to return only values that occur exactly once. Optional

Examples

Get unique values from list

=UNIQUE(A1:A5)
Result ⇒ Array: [["Apple"], ["Banana"], ["Cherry"]]
A
1 Apple
2 Banana
3 Apple
4 Cherry
5 Banana

Find values that occur only once

=UNIQUE(A1:A4, false, true)
Result ⇒ Array: [["Blue"], ["Green"]]
A
1 Red
2 Blue
3 Red
4 Green

Unique rows in table

=UNIQUE(A1:B4)
Result ⇒ Array: [["A","1"], ["B","2"], ["C","3"]]
A B
1 A 1
2 B 2
3 A 1
4 C 3

Related Functions

Other Data functions:


← Back to Formula Reference