dblink (INSERT ..... RETURNING)

From: "P(dot) Broennimann" <peter(at)enovatiq(dot)com>
To: pgsql-general(at)postgresql(dot)org
Subject: dblink (INSERT ..... RETURNING)
Date: 2012-01-20 08:20:51
Message-ID: CACm4aU9jrxohYOYzcoNFbtOJD3Zq_Q7nMMyD6wRkcoSTtBYrEQ@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Hi there

I have a remote table that I access over dblink.
The table has a primary field set to "autoincrement".

I need now to insert a record in that remote table and get back the new
primary field (autoincrement sequence).

Since "bdlink_exec" can not give back rows I tried to use "dblink", but I
can not figure out how to format that INSERT... RETURNING query?

Thanks,
P.

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Florian Weimer 2012-01-20 08:27:55 Re: On duplicate ignore
Previous Message Mark van Leeuwen 2012-01-20 07:18:04 Re: Exclusive row locks not release