Waiting for 8.4 – sequence details

On 15th of July, Bruce Momjian commited patch written by Dickson S. Guedes, which:

Have psql \d show the value of sequence columns.

before it, output of \d of sequence was like this:

# \d some_sequence
Sequence "public.some_sequence"
    Column     |  Type
---------------+---------
 sequence_name | name
 last_value    | bigint
 increment_by  | bigint
 max_value     | bigint
 min_value     | bigint
 cache_value   | bigint
 log_cnt       | bigint
 is_cycled     | boolean
 is_called     | boolean

but now, with this patch, output looks like this:

# \d some_sequence
        Sequence "public.some_sequence"
    Column     |  Type   |        Value
---------------+---------+---------------------
 sequence_name | name    | testa_id_seq
 last_value    | bigint  | 5
 start_value   | bigint  | 1
 increment_by  | bigint  | 1
 max_value     | bigint  | 9223372036854775807
 min_value     | bigint  | 1
 cache_value   | bigint  | 1
 log_cnt       | bigint  | 28
 is_cycled     | boolean | f
 is_called     | boolean | t

While all of this information was actually available before with simple:

SELECT * FROM public.some_sequence

it's nice to have it available in a easier way.

One thought on “Waiting for 8.4 – sequence details”

  1. I think that this output must be under \d+ command… [good enhancement]

Comments are closed.