From: | Daniel Péder <dpeder(at)infoset(dot)cz> |
---|---|
To: | "'pgsql-hackers(at)postgresql(dot)org'" <pgsql-hackers(at)postgresql(dot)org>, "'pgsql-sql(at)postgresql(dot)org'" <pgsql-sql(at)postgresql(dot)org> |
Subject: | insertable views - not copy-able ? |
Date: | 1999-10-17 20:56:45 |
Message-ID: | 01BF18EA.81DB25A0@Dan |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers pgsql-sql |
what about this:
( it would be nice to have it working, specially for copying values from files into table with default fields, having the default fields doing their job or initialising tables using reduced set of columns )
mydb=> create sequence MYSEQ;
CREATE
mydb=> create table MYTAB ( ID int4 default nextval('MYSEQ'), NAME text );
CREATE
mydb=> create view MYVIEW as select name from MYTAB;
CREATE
mydb=> copy MYVIEW from stdin;
Enter info followed by a newline
End with a backslash and a period on a line by itself.
>> jim
>> john
>> jack
>> \.
mydb=> select MYVIEW.*;
name
----
(0 rows)
--
dan peder
dpeder(at)infoset(dot)cz
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 1999-10-17 21:47:11 | Re: [HACKERS] don't know whether nodes of type 719 are equal |
Previous Message | Peter Eisentraut | 1999-10-17 20:29:50 | Re: [HACKERS] pg_type questions |
From | Date | Subject | |
---|---|---|---|
Next Message | Dipankar Chakrabarti | 1999-10-18 06:05:02 | Pg_dump for a database with Procedural Language |
Previous Message | Tom Lane | 1999-10-17 15:58:00 | Re: [SQL] NOT NULL and postgres 6.5.2 |