From: | ZongtianHou <zongtianhou(at)icloud(dot)com> |
---|---|
To: | Laurenz Albe <laurenz(dot)albe(at)cybertec(dot)at> |
Cc: | pgsql-admin <pgsql-admin(at)postgresql(dot)org> |
Subject: | Re: how to insert row with specific oid |
Date: | 2020-06-19 07:17:18 |
Message-ID: | 8138D6E3-C631-48B9-8F18-7F21BBE3520B@icloud.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-admin |
Thank you for the detailed answer!
> On Jun 19, 2020, at 3:13 PM, Laurenz Albe <laurenz(dot)albe(at)cybertec(dot)at> wrote:
>
> On Fri, 2020-06-19 at 15:02 +0800, ZongtianHou wrote:
>> Could I insert a row to table with specific row oid. just like insert
>> into tbl values (xx,xx) oid=xx? Is there some syntax to do this?
>
> No, you cannot determine the OID that will be inserted.
>
> Using tables WITH OIDS is deprecated, and the feature is gone in v12.
>
> If you want to insert specific values, you shouldn't be using a
> system-generated OID but a regular column of type "bigint" or so.
>
> Yours,
> Laurenz Albe
> --
> Cybertec | https://www.cybertec-postgresql.com
>
From | Date | Subject | |
---|---|---|---|
Next Message | Pepe TD Vo | 2020-06-19 11:12:30 | Re: create batch script to import into postgres tables |
Previous Message | Laurenz Albe | 2020-06-19 07:13:09 | Re: how to insert row with specific oid |