Andrey wrote:
> select id, first_value(id) over(order by id), last_value(id) over(order by
> id) from t;
> 
> RESULT:
>  id | first_value | last_value
> ----+-------------+------------
>   1 |           1 |          1
>   2 |           1 |          2
>   3 |           1 |          3
> (3 rows)
> 
> fist_value - good, last_value - bad

Looks ok to me. What did you expect?

-- 
  Heikki Linnakangas
  EnterpriseDB   http://www.enterprisedb.com

-- 
Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-bugs

Reply via email to