By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
438,007 Members | 1,248 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 438,007 IT Pros & Developers. It's quick & easy.

Controling tablespace for a primary key index in alter table

P: 3
Hi,
Using DB2 version 9, fixpak 2 on AIX 5L.

I created my DDL for defining a Primary Key to be done by a ALTER TABLE command, but I could not find a way of naming the tablespace to control were the index that gets created goes.

I did find that I could create the table with the clause "INDEX IN ...", name the tablespace I wanted and then when the ALTER TABLE ran it resulted in the index going into the tablespace I wanted. I guess I could also pre-create the index.

But is there a way of specifying the tablespace in an ALTER TABLE ADD CONSTRAINT ... command? I would prefer to do it that way, because it makes it explict where the index is going to go, when for what ever reason the constraint has to be dropped and re-created.

Regards

Pete
Jul 10 '07 #1
Share this question for a faster answer!
Share on Google+

Post your reply

Sign in to post your reply or Sign up for a free account.