Re: issues with dropped columns in plpgsql code again - Mailing list pgsql-hackers

From Szymon Guz
Subject Re: issues with dropped columns in plpgsql code again
Date
Msg-id CAFjNrYuCAEj9WioOz-10Bx4+gfdsO0YMVAPU_bKsybwipNQUsg@mail.gmail.com
Whole thread Raw
In response to Re: issues with dropped columns in plpgsql code again  (Pavel Stehule <pavel.stehule@gmail.com>)
List pgsql-hackers
On 7 May 2013 21:23, Pavel Stehule <pavel.stehule@gmail.com> wrote:
sorry

my test

create table f1(a int, b int, c varchar, dropped_column numeric, d varchar);

create or replace function f1_trg()
returns trigger as $$
declare _f1_var f1;
begin raise notice 'run trigger';
  _f1_var := new;
  return _f1_var;
end;
$$ language plpgsql;

create trigger xx before insert on f1 for row execute procedure f1_trg();

insert into f1 values(1,1,'aaa',1.1,'aaa');
alter table f1 drop column dropped_column ;

insert into f1 values(1,1,'aaa','aaa');



Fails for me as well. I managed to run the last query either with restarting session, or disabling the trigger.

Checked that on PostgreSQL 9.2.4 on x86_64-unknown-linux-gnu, compiled by gcc (Ubuntu/Linaro 4.7.2-2ubuntu1) 4.7.2, 64-bit 

regards,
Szymon

pgsql-hackers by date:

Previous
From: Jeff Janes
Date:
Subject: Re: XLogFlush invoked about twice as much after 9.2 group commit enhancement
Next
From: Peter Geoghegan
Date:
Subject: local_preload_libraries logspam