On Mon, Dec 2, 2024 at 12:06 AM Sergei Kornilov wrote:
>
> Hello!
> Thanks for the patch, but I think using SPI is still not allowed here:
> https://www.postgresql.org/message-id/9878.1511970441%40sss.pgh.pa.us
>
> > if it uses SPI for sub-operations of ALTER TABLE I think that is sufficient
> >
Sergei Kornilov writes:
> Hello!
> Thanks for the patch, but I think using SPI is still not allowed here:
> https://www.postgresql.org/message-id/9878.1511970441%40sss.pgh.pa.us
Yeah, if you want to do this you need to code the catalog lookup in
C. SPI just adds too many variables to what will
Hello!
Thanks for the patch, but I think using SPI is still not allowed here:
https://www.postgresql.org/message-id/9878.1511970441%40sss.pgh.pa.us
> if it uses SPI for sub-operations of ALTER TABLE I think that is sufficient
> reason to reject it out of hand.
regards, Sergei
hi.
attached patch trying to speedup ALTER TABLE ADD CHECK CONSTRAINT.
demo:
drop table if exists t7;
create table t7 (a int not null, b int, c int);
insert into t7 select g, g+1, g %100 from generate_series(1,1_000_000) g;
create index on t7(a,b);
alter table t7 add check (a > 0);
patch: T