win_func_into_udf.sql 174 B

123456
  1. /* postgres can not */
  2. SELECT
  3. key, Math::Sqrt(CAST(row_number() over w as double)) as sq
  4. FROM plato.Input
  5. WINDOW w AS (partition by key order by subkey)
  6. ORDER BY key, sq;