sql - How to show row numbers in PostgreSQL query? -


I want to show an overview number for each record received by a PostgreSQL query.

I 8.4 can display this capability in windowing functions.

  select row_number () more than (by sequence & lt; region & gt; ), * Foo_tbl by command & lt; Field & gt;  

If the command is not necessary, then this answer may also be simplified:

  select row_number () over (), * - Notice: a field Not required from Foo_tbl  

Comments

Popular posts from this blog

Eclipse CDT variable colors in editor -

AJAX doesn't send POST query -

wpf - Custom Message Box Advice -