![]() | |
![]() |
| | Thread Tools | Display Modes |
#1
| |||
| |||
|
#2
| |||
| |||
|
|
I am trying to get the admin_move_table command to work to move a table from one tablespace to another. Got it to work on a simple dummy table, but when using a complex table with range partitions, the results have been less than stellar. Upon completion, my new tablespace is -6 (negative six) which doesn't show up as a catalogued tablespace. On subsequent attempts to move I frequently get a SQL1142 error where a temp file already exists. The documentation is very sparse so it's hard to see what I might be doing wrong. I'm running 9.7.3 on a partitioned Linux environment. My command is below. Any insight would be appreciated. call sysproc.admin_move_table ( 'LRM', 'MIGRATE_TEST_4', 'TS_LRM_POS_HIST_D', 'TS_LRM_POS_HIST_D', 'L '', '', 'COPY_USE_LOAD', 'MOVE' ); |
#3
| |||
| |||
|
|
Unless you need to do this online while users are accessing the table, it is almost as easy to just create a new table in the new tablespace, export the data from old and load into new table, and then rename old and new tables. You will have handle FK's and other dependent objects manually. |
#4
| |||
| |||
|
|
Unless you need to do this online while users are accessing the table, it is almost as easy to just create a new table in the new tablespace, export the data from old and load into new table, and then rename old and new tables. You will have handle FK's and other dependent objects manually. Thanks for your input, Mark. *We've looked at *the re-create/export/ reload scenario, but online availability is important as are the multiple dependencies such as hundreds of views that the application creates for itself. That's why we were excited by the purported benefits of this procedure. The manual move is much speedier than the proc for the record. We'll keep experimenting and plugging along. Evan |
#5
| |||
| |||
|
|
but when using a complex table with range partitions, the results have been less than stellar. Upon completion, my new tablespace is -6 (negative six) which doesn't show up as a catalogued tablespace. |
![]() |
| Thread Tools | |
| Display Modes | |
| |