Re: [SPAM] Re: Partial table duplication via triggger

2024-02-22 Thread Moreno Andreo
On 22/02/24 17:49, Erik Wienhold wrote: On 2024-02-22 15:14 +0100, Moreno Andreo wrote: suppose I have 2 tables [snip] What am I missing? The parameters you pass in with USING have to be referenced as $1, $2, and so on. For example: DECLARE fieldlist text := (

Re: Partial table duplication via triggger

2024-02-22 Thread Erik Wienhold
On 2024-02-22 15:14 +0100, Moreno Andreo wrote: > suppose I have 2 tables > > CREATE TABLE t1( >     id uuid, >     name text, >     surname text, >     ... >     PRIMARY KEY(id) > ) > > CREATE TABLE t2( >     id uuid, >     master_id uuid, >     op_ts timestamp with time zone, >     name text, >

Partial table duplication via triggger

2024-02-22 Thread Moreno Andreo
Hi *,     suppose I have 2 tables CREATE TABLE t1(     id uuid,     name text,     surname text,     ...     PRIMARY KEY(id) ) CREATE TABLE t2(     id uuid,     master_id uuid,     op_ts timestamp with time zone,     name text,     surname text,     ...     PRIMARY KEY(id) ) I need to write an