[Postgres-xl-developers] Question about currval

Gustavo Rincon gustavo.rincon at ymail.com
Wed Aug 3 08:56:52 PDT 2016

Hi Joshua
    Unfortunately the framework used in our application relay on currval and it will be allow of work to refactor it.
    Thanks for you help.


    On Wednesday, August 3, 2016 10:48 AM, Joshua D. Drake <jd at commandprompt.com> wrote:

 On 08/03/2016 08:35 AM, Gustavo Rincon wrote:
> Hi,
>                I’m trying to retrieve the sequence id assigned to a row
> after inserting using SELECT currval statement, but the following error
> is returned:
> ERROR:  currval of sequence "content_type_seq" is not yet defined in
> this session
>                  Does the postgres-xl does not support any more currval

I can't answer your specific question but I can make your life easier:

INSERT into content_type (name) values ('image/jpeg') RETURNING id;


Command Prompt, Inc.                  http://the.postgres.company/
PostgreSQL Centered full stack support, consulting and development.
Everyone appreciates your honesty, until you are honest with them.
Unless otherwise stated, opinions are my own.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.postgres-xl.org/private.cgi/postgres-xl-developers-postgres-xl.org/attachments/20160803/04027d1b/attachment.htm>

More information about the Postgres-xl-developers mailing list