Re: Sequences problem

From: Andrew Sullivan <ajs(at)crankycanuck(dot)ca>
To: pgsql-sql(at)postgresql(dot)org
Subject: Re: Sequences problem
Date: 2007-08-17 21:49:10
Message-ID: 20070817214910.GE29125@phlogiston.dyndns.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

On Fri, Aug 17, 2007 at 04:33:04PM -0500, Judith wrote:
> When I init a sesion with my db, if a do the next sentence:
>
> SELECT currval('pagos_id_pago_seq');
>
>
> return this:
> ERROR: the relation doesn't exist
> (or somethimg like that, because the message is in spanish)

You _must_ call nextval() before a currval(). This is documented
behaviour.

A

--
Andrew Sullivan | ajs(at)crankycanuck(dot)ca
The whole tendency of modern prose is away from concreteness.
--George Orwell

In response to

Browse pgsql-sql by date

  From Date Subject
Next Message Scott Marlowe 2007-08-17 21:50:00 Re: Sequences problem
Previous Message Judith 2007-08-17 21:33:04 Sequences problem