From: | "Ashley (at) Turton" <ashley(at)turton(dot)com> |
---|---|
To: | <pgsql-general(at)postgresql(dot)org> |
Subject: | Blank SQL insert statements |
Date: | 2001-10-17 08:24:42 |
Message-ID: | B7F2FEDA.5416%ashley@turton.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
I am developing a system to take a generic data structure and store it in a
PostgreSQL database. The data structure contains several entries of the
following:
insert a record into table1
field1 value1
field2 value2
insert a record into table2
field1 value1
field2 value2
Data for different tables is stored in each 'data set'. When I get this to
the database I want to:
insert a blank record into tablex
populate fieldx of new record with valuex
I could implement this with some if statements based on the table name, then
INSERT INTO x (...) VALUES (...), but I would prefer to kept the structure
as generic as possible. Is it possible in PostgreSQL to construct a blank
record without specifying a list of fields and values in an INSERT statement
(so I can perform a collection for UPDATEs to populate the blank record)?
Ashley
From | Date | Subject | |
---|---|---|---|
Next Message | Steve Brett | 2001-10-17 08:48:09 | URGENT: Index problems |
Previous Message | Jan Poslusny | 2001-10-17 08:23:23 | Re: |