Compatible with PostgreSQL, Hologres allows you to use standard PostgreSQL syntax for data development.

The following table describes the set returning functions supported by Hologres. The functions supported by Hologres are only a subset of the PostgreSQL functions. For more information about how to use these functions, see Set Returning Functions in the PostgreSQL documentation.
Function Description Example Result
generate_series(start, stop) Generates a numeric sequence with a step size of 1 from the value specified by start to the value specified by stop. generate_series(2,4) generate_series----------------- 2 3 4(3 rows)
generate_series(start, stop, step) Generates a numeric sequence with a specified step size from the value specified by start to the value specified by stop.
Note The arguments are of the INT, BIGINT, or NUMERIC data type.
generate_series(5,1,-2) generate_series----------------- 5 3 1(3 rows)
generate_series(start, stop, step interval) Generates a numeric sequence with a specified step size from the value specified by start to the value specified by stop.
Note The arguments are of the TIMESTAMP or TIMESTAMP WITH TIME ZONE data type.
generate_series('2008-03-01 00:00'::timestamp, '2008-03-04 12:00', '10 hours') generate_series --------------------- 2008-03-01 00:00:00 2008-03-01 10:00:00 2008-03-01 20:00:00 2008-03-02 06:00:00 2008-03-02 16:00:00 2008-03-03 02:00:00 2008-03-03 12:00:00 2008-03-03 22:00:00 2008-03-04 08:00:00(9 rows)
generate_subscripts(array anyarray, dim int) Generates a set of valid subscripts for the specified dimension of a given array. generate_subscripts('{NULL,1,NULL,2}'::int[], 1) s --- 1 2 3 4(4 rows)