groupArraySample
Creates an array of sample argument values. The size of the resulting array is limited to max_size elements. Argument values are selected and added to the array randomly.
Syntax
Arguments
max_size— Maximum size of the resulting array. UInt64.seed— Seed for the random number generator. Optional. UInt64. Default value:123456.x— Argument (column name or expression).
Returned values
- Array of randomly selected
xarguments.
Type: Array.
Examples
Consider table colors:
Query with column name as argument:
Result:
Query with column name and different seed:
Result:
Query with expression as argument:
Result: