All Questions
Tagged with inheritance insert
3 questions
-1
votes
1
answer
51
views
How to INSERT a new record into 2 tables with FKEY inheritance?
Inheritance has been setup with FKEY instead of INHERITS due to FKEY limitation.
My question: How to INSERT a new record into bonds table?
CREATE TABLE IF NOT EXISTS instruments (
id SERIAL,
...
0
votes
1
answer
78
views
Move row of a table to an inherited table in PostgreSQL
I have tables created as such:
BEGIN;
CREATE TABLE tag (
id SERIAL,
name VARCHAR(255) UNIQUE NOT NULL,
description VARCHAR(511) NOT NULL DEFAULT '',
PRIMARY KEY(id)
)...
11
votes
5
answers
56k
views
Insert into select into multiple related tables using INSERT_IDENTITY
Okay setting the scene. I have three tables, (Table1, Table2 and DataTable) and I want to insert into Table1 and Table2 using DataTable as source.
So for every row in DataTable I want a row in Table1 ...