Shouldn't CREATE TABLE LIKE copy the relhasoids property?

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Shouldn't CREATE TABLE LIKE copy the relhasoids property?
Дата
Msg-id 18543.1421281764@sss.pgh.pa.us
обсуждение исходный текст
Ответы Re: Shouldn't CREATE TABLE LIKE copy the relhasoids property?  (Andrew Dunstan <andrew@dunslane.net>)
Re: Shouldn't CREATE TABLE LIKE copy the relhasoids property?  (Bruce Momjian <bruce@momjian.us>)
Список pgsql-hackers
dst1 doesn't get an OID column:

regression=# create table src1 (f1 int) with oids;
CREATE TABLE
regression=# create table dst1 (like src1);
CREATE TABLE
regression=# \d+ src1                        Table "public.src1"Column |  Type   | Modifiers | Storage | Stats target |
Description
 
--------+---------+-----------+---------+--------------+-------------f1     | integer |           | plain   |
  | 
 
Has OIDs: yes

regression=# \d+ dst1                        Table "public.dst1"Column |  Type   | Modifiers | Storage | Stats target |
Description
 
--------+---------+-----------+---------+--------------+-------------f1     | integer |           | plain   |
  | 
 


If you don't find that problematic, how about this case?

regression=# create table src2 (f1 int, primary key(oid)) with oids;
CREATE TABLE
regression=# create table dst2 (like src2 including indexes);
ERROR:  column "oid" named in key does not exist
        regards, tom lane



В списке pgsql-hackers по дате отправления:

Предыдущее
От: Merlin Moncure
Дата:
Сообщение: Re: hung backends stuck in spinlock heavy endless loop
Следующее
От: Tom Lane
Дата:
Сообщение: Re: s_lock.h default definitions are rather confused