Subject | Mass index activation. |
---|---|
Author | Ann W. Harrison |
Post date | 2004-12-16T20:26:15Z |
At 09:49 AM 12/16/2004, giovanibettiol wrote:
that enforce primary key and unique constraints, then
all the rest.
update rdb$indices set rdb$index_inactive = 0
where rdb$unique_flag = 1;
commit;
update rdb$indices set rdb$index_inactive = 0
where rdb$index_inactive = 1;
commit;
Alternately, activate all the indexes that aren't foreign
key indexes, then activate the foreign key indexes.
update rdb$indices set rdb$index_inactive = 0
where rdb$foreign_key is NULL;
commit;
update rdb$indices set rdb$index_inactive = 0
where rdb$foriegn_key is not NULL;
commit;
Cheers,
Ann
> Just one more question: is there a way to activateYou should activate indexes in two steps - first those
>all the indexes in a single statement?
that enforce primary key and unique constraints, then
all the rest.
update rdb$indices set rdb$index_inactive = 0
where rdb$unique_flag = 1;
commit;
update rdb$indices set rdb$index_inactive = 0
where rdb$index_inactive = 1;
commit;
Alternately, activate all the indexes that aren't foreign
key indexes, then activate the foreign key indexes.
update rdb$indices set rdb$index_inactive = 0
where rdb$foreign_key is NULL;
commit;
update rdb$indices set rdb$index_inactive = 0
where rdb$foriegn_key is not NULL;
commit;
Cheers,
Ann