distinct operator will aggregate all of the distinct values of the given columns.
table | distinct column1, column2, column3
Be aware of cardinality here. This is a very memory intensive operation, as the result set needs to be kept available as the aggregations runs. Make sure you use rounding operators (like ‘bin’) on high-cardinality values, like timestamps.