Connecting Tech Pros Worldwide Help | Site Map
 
 
LinkBack Thread Tools Search this Thread
  #1  
Old August 27th, 2008, 01:15 AM
mvsmsh
Guest
 
Posts: n/a
Default How to move tables into different tablespace ?

Hi,

Are there any procedure or commands
moving one table into new tablespace from old tablespace , where it
has multiple tables in one tablespace ?


Here's my scenario for moving sample_table into tablespace_new

1. create tablespace_new
2. create table "sample_table_new " in tablespace_new
3. Stop user service
4. load sample_table_new from sampe_table
5. drop all relations on sample_table
view , trigger, foreign key, constraints.
( It so tricky and hard part ,
when it got multiple constrains over multiple tables )

6. Rename sample_table to sample_table_old
Rename sample_table_new to sample_table
7. Create all relations to sample_table
8. Start user service
9. Drop sample_table_old



Env : AIX 5.3/UDB V8.2

Regards
Myoungsoo



  #2  
Old September 2nd, 2008, 11:05 AM
Frederik
Guest
 
Posts: n/a
Default Re: How to move tables into different tablespace ?

Hello Myoungsoo,

This link might be of some use to you. Perhaps you could get your
hands on this (although I formally oppose this idea and suggest you
use this guide to roll your own version):

http://doyoudb2.com/sap-related/50-o...r-sap-db2-dbas

Kind Regards,

Frederik

On Aug 27, 2:07*am, mvsmsh <mvs...@gmail.comwrote:
Quote:
Hi,
>
Are there any procedure or commands
moving one table into new tablespace from old tablespace , where it
has multiple tables in one tablespace ?
>
Here's my scenario for moving sample_table into tablespace_new
>
1. create tablespace_new
2. create table *"sample_table_new " in tablespace_new
3. Stop user service
4. load *sample_table_new *from *sampe_table
5. drop *all relations *on sample_table
* * view , trigger, foreign key, constraints.
* *( It so tricky *and hard part ,
* * *when it got multiple constrains over multiple tables )
>
6. Rename sample_table * * *to sample_table_old
* *Rename sample_table_new *to sample_table
7. Create all relations *to sample_table
8. Start user service
9. Drop sample_table_old
>
Env : AIX 5.3/UDB V8.2
>
Regards
Myoungsoo
 

Bookmarks

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Popular Articles

What is Bytes?

We are a network of experts and professionals in IT and software development that help one another with answers to tough questions and share insights. Get the best answers to your questions from over 205,414 network members.