Move index to a different tablespace using dbms_redefinition?
Hi all, I am trying to move indexes to new tablespaces. Can I use oracle built-in package DBMS_REDEFINITION for this? As far as I know dbms_redefinitoin only works for tables rebuilt online? I am running 10.2.0.5 on linux red hat, and the index sizes from 100MB to 10gb. Thank you in advance all.
Since one can seamlessly move an index from one tablespace to another by simply doing:
SQL> alter index <index_name> rebuild tablespace <tablespace_name>;even considering DBMS_REDEFINITION for this makes no sense at all.
If your boss has any further questions, show him the Oracle documentation:
http://download.oracle.com/docs/cd/B19306_01/appdev.102/b14258/d_redefi.htm
Quote from that page:
"The DBMS_REDEFINITION package provides an interface to perform an *online redefinition of tables*."
(Emphasis added by me.)
Hope that helps,
-Mark
Similar Messages
-
Move indexes to a different tablespace
What is the best and easiest method to move all indexes/constraints to a different tablespace. I have 2 tablespaces one for data and the other for the indexes. At present, I have all data and indexes all in one tablespace. I would like to separate the indexes to another tablespace(which is reserved specifically for the indexes)
ThanksYou do not move constraints.
You can use the command:
ALTER INDEX index_name REBUILD TABLESPACE new_tablespace; -
Moving indexes to a different tablespace in siebel.
Hi,
While installation we gave same SIEBEL tablespace as default tablespace for indexes also , now I would like to move all indexes to a different tablespace. Is there any specifis utility / procedure available to move (or) recreate indexes .. or can we do it in Database using alter index <index_name> command...
Thank You,
Sunil.You do not move constraints.
You can use the command:
ALTER INDEX index_name REBUILD TABLESPACE new_tablespace; -
How to move lobsegment and lobindex to a different Tablespace
Oracle Version: Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - 64bit
Os: Solaris 10
Hello Everybody,
I want to move a lobsegment and a lobindex to a differrent tablespace.
But when i am executing the following statement in order to move the LOBINDEX I am getting the errors listed below:
SQL> ALTER INDEX SYS_IL0000012358C00008$$ REBUILD TABLESPACE INDX;
ALTER INDEX SYS_IL0000012358C00008$$ REBUILD TABLESPACE INDX
ERROR at line 1:
ORA-02327: cannot create index on expression with datatype LOB
Is there any differrent commands/methods of moving the LOBSEGMENT/LOBINDEX to a differrent tablespace.
Any help Appreciated..
Regards,
Prosenjit Mukherjee.Hi,
Assuming that I have table "TEST" in USERS TableSpace
CREATE TABLE TEST
TEST_ID NUMBER NOT NULL,
TEST_NAME CLOB,
CONSTRAINT PK_TEST PRIMARY KEY(TEST_ID)
SQL> ALTER TABLE TEST MOVE TABLESPACE EXAMPLE;
Above command will move the table to new tablespace but will not move the CLOB segment and it will still be in original tablespace. This is because LOB data is stored outside of the table.
Check the tablespace of the CLOB column by issuing following sql.
SQL> SELECT index_name, tablespace_name
FROM user_indexes WHERE table_name = ‘TEST’;
INDEX_NAME TABLESPACE_NAME
SYS_IL0000073575C00002$$ USERS
In order to move CLOB column to different tablespace, we have to issue following command.
SQL> ALTER TABLE TEST MOVE LOB(TEST_NAME) STORE AS (TABLESPACE EXAMPLE);
In above example, TEST_NAME is the CLOB column which we want to move to new tablespace and EXAMPLE is target tablespace. Above command will successfully move LOB segments to the new tablespace. We can verify it by issuing same sql again.
SQL> SELECT index_name, tablespace_name
FROM user_indexes WHERE table_name = ‘TEST’;
INDEX_NAME TABLESPACE_NAME
SYS_IL0000073575C00002$$ EXAMPLE
- Pavan Kumar N -
Index on different tablespaces
I need to move some indexes on a different tablespace. How can I complete this task ? I'm not a dba..
Have a look at these links:
http://docs.oracle.com/cd/E11882_01/server.112/e26088/statements_1010.htm#SQLRF00805
http://docs.oracle.com/cd/E11882_01/server.112/e25494/indexes004.htm#ADMIN11732
ALTER INDEX YOUR_INDX REBUILD TABLESPACE YOUR_TBS; -
How do I move apps to different pages using my PC?
Wondering how to move iPad apps to different pages using (a) my PC and (b) my iPad. Thanks!
See the following articles:
http://ipadnotebook.wordpress.com/2012/12/10/how-to-use-itunes-11-to-arrange-app s/
http://www.cnet.com/how-to/how-to-arrange-iphone-and-ipad-apps-using-itunes/ -
Table and index in the same tablespace
I have a table and its associated indexes all in one tablespace. Now, will creating a separate tablespace just for the indexes and drop and recreating the indexes the table has in the new tablespace help ???
ThanksIn all probability, no. This may have some housekeeping/ recovery benefits but it is very unlikely to have performance benefits. Most modern disk arrays are configured so that data access is spread pretty evenly across all the spindles. If your disk is configured such that you have "hot" and "cold" disks, and if you can move the index to a different tablespace that can be placed on one of the "cold" disks, this will tend to balance out disk I/O and may improve performance.
Justin
Distributed Database Consulting, Inc.
http://www.ddbcinc.com/askDDBC -
How to move partitions/sub-partitions into a different tablespace?
Hi Uisng oracle 1..20.3 and have a range-hash partitioned table using interval partitioning - code below.
Works fine just one problem.
we wish to move the system geneerated partitions to different tablespaces later and also rename th epartitions.
When try assign partition to a different tablespace get the folloiwng message
alter table por_rt move partition SYS_P2283 tablespace bi_dw_data
get message ora-14257 - cannot move partition other than range,list, system or hash partition.
How can we avoid this.
We we need to move all the subpartitions first?
Tried this
alter table move subpartition SYS_SUBP2269 tablespace bi_dw_data;
but get message ora-01735 message invalid statement
-- Create table
create table POR_RT
plant_issue_id NUMBER not null,
pf_run_num NUMBER,
partitioning_date DATE
partition by range (PARTITIONING_DATE)
subpartition by hash (PLANT_ISSUE_ID)
partition PART_200912 values less than (TO_DATE(' 2010-01-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN'))
tablespace BI_SUPPORT_DATA
pctfree 10
initrans 1
maxtrans 255
subpartition SYS_SUBP2261 tablespace BI_SUPPORT_DATA,
subpartition SYS_SUBP2262 tablespace BI_SUPPORT_DATA,
subpartition SYS_SUBP2263 tablespace BI_SUPPORT_DATA,
subpartition SYS_SUBP2264 tablespace BI_SUPPORT_DATA
partition PART_201001 values less than (TO_DATE(' 2010-02-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN'))
tablespace BI_SUPPORT_DATA
pctfree 10
initrans 1
maxtrans 255
subpartition SYS_SUBP2265 tablespace BI_SUPPORT_DATA,
subpartition SYS_SUBP2266 tablespace BI_SUPPORT_DATA,
subpartition SYS_SUBP2267 tablespace BI_SUPPORT_DATA,
subpartition SYS_SUBP2268 tablespace BI_SUPPORT_DATA
partition SYS_P2273 values less than (TO_DATE(' 2010-03-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN'))
tablespace BI_SUPPORT_DATA
pctfree 10
initrans 1
maxtrans 255
subpartition SYS_SUBP2269 tablespace BI_SUPPORT_DATA,
subpartition SYS_SUBP2270 tablespace BI_SUPPORT_DATA,
subpartition SYS_SUBP2271 tablespace BI_SUPPORT_DATA,
subpartition SYS_SUBP2272 tablespace BI_SUPPORT_DATA
partition SYS_P2283 values less than (TO_DATE(' 2010-07-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN'))
tablespace BI_SUPPORT_DATA
pctfree 10
initrans 1
maxtrans 255
subpartition SYS_SUBP2279 tablespace BI_SUPPORT_DATA,
subpartition SYS_SUBP2280 tablespace BI_SUPPORT_DATA,
subpartition SYS_SUBP2281 tablespace BI_SUPPORT_DATA,
subpartition SYS_SUBP2282 tablespace BI_SUPPORT_DATA
partition SYS_P2278 values less than (TO_DATE(' 2010-08-01 00:00:00', 'SYYYY-MM-DD HH24:MI:SS', 'NLS_CALENDAR=GREGORIAN'))
tablespace BI_SUPPORT_DATA
pctfree 10
initrans 1
maxtrans 255
subpartition SYS_SUBP2274 tablespace BI_SUPPORT_DATA,
subpartition SYS_SUBP2275 tablespace BI_SUPPORT_DATA,
subpartition SYS_SUBP2276 tablespace BI_SUPPORT_DATA,
subpartition SYS_SUBP2277 tablespace BI_SUPPORT_DATA
);Edited by: user5716448 on 22-Mar-2013 04:49you can not move composite parition directly you need to move subpartition using this statments
alter table <tablename> move subpartition <sub partition name > tablespace <tablespace name>;
than change partition tablespace using
ALTER TABLE <table name> MODIFY DEFAULT ATTRIBUTES FOR PARTITION <partition name> TABLESPACE <tablespace name>; -
I'm using Photoshop CC 2014, when I open a picture and movie it to a different Photoshop page, the picture turns black and white. How do I fix this problem?
Nobody can tell you anything without proper system info or other technical details since even your terminology is confusing. there are no "pages" in Photoshop. What you describe in vague terms could be anything from your target document having a different color mode/ color profile to some hardware acceleration issue, but we really can't make any sense of it based on your information.
Mylenium -
How to move indexes to another tablespace through script
Hi Dear,
How i can move indexes to another tablespace through a script which just gets new tablespace name, owner name and move and rebuild indexes in one go.
Thank u for your prompt Help.
RegardsHi,
alter session set sort_area_size = 15000000;
spool index.sql
select 'alter index '||owner||'.'||index_name||' rebuild tablespace TARGET_TBS;'
from dba_indexes
where tablespace_name = 'INIT_TBS'
@index.sql
This script move and rebuild index from one tablespace INIT_TBS to an other tablespace TARGET_TBS
Hope this help you
Nicolas. -
Hi all,
I am new in manufacturing and we want to implement functionality of generating single move order for same component among different job using component pick release. Can any one help in this.
we are using oracle R 12.1.3 version.
For example. We create finish good XYZ which is build in WIP item. We create discrete jobs for XYZ suppose JOB1,JOB2,JOB3 multiple job we can create for XYZ item. in these JOB suppose component abc is similar with 5 quantity. so our goal is to generate 1 move order for all three JOBS with 15 quantity of abc component.
please help me to achieve this goal. Immediate Reply will be appreciated.
Thanks & Regards
user11152750PranitSaha
Thanks For your reply. Can you please tell me in detail how can I group as I am new. How using MRP we can group same component from different job in single move order for delivering that component to shop floor.
Thank you.. -
User_lobs and user_segments view shows different tablespace for lob segment
Hi,
I am trying to move lob in different tablespace for partitioned table.
I used
alter table <table_name> move partition <partition_name> lob(lob_column) store as (tablespace <tablespace_name>);
alter index <index_name> rebuild partition <partition_name> tablespace <tablespace_name>
ALTER TABLE <table_name> MODIFY DEFAULT ATTRIBUTES TABLESPACE <tablespace_name>
ALTER INDEX <index_name> modify default ATTRIBUTES TABLESPACE <tablespace_name>
Database - 10.2.0.5
OS- HP Itanium 11.31
I can see in user_lob_partitions, user_segments and user_part_tables shows me new tablespace information
whereas user_lobs and user_part_indexes shows me different information regarding tablespace.
I checked some documents in metalink but didnt help me.
I think that I am missing something or doing some step wrong.
Please help.
SQL> select partition_name, lob_partition_name, tablespace_name from user_lob_partitions where table_name in ('TRB1_PUB_LOG','TRB1_SUB_ERRS','TRB1_PUB_LOG') ;
PARTITION_NAME LOB_PARTITION_NAME TABLESPACE_NAME
S2000 SYS_LOB_P8585 USAGE_REORG_TBS
S2001 SYS_LOB_P8587 USAGE_REORG_TBS
S2003 SYS_LOB_P8589 USAGE_REORG_TBS
S2004 SYS_LOB_P8591 USAGE_REORG_TBS
S2005 SYS_LOB_P8593 USAGE_REORG_TBS
S2006 SYS_LOB_P8595 USAGE_REORG_TBS
S2007 SYS_LOB_P8597 USAGE_REORG_TBS
S2008 SYS_LOB_P8599 USAGE_REORG_TBS
S2010 SYS_LOB_P8601 USAGE_REORG_TBS
S2011 SYS_LOB_P8603 USAGE_REORG_TBS
S2012 SYS_LOB_P8605 USAGE_REORG_TBS
S2013 SYS_LOB_P8607 USAGE_REORG_TBS
S2014 SYS_LOB_P8609 USAGE_REORG_TBS
S2015 SYS_LOB_P8611 USAGE_REORG_TBS
S2888 SYS_LOB_P8613 USAGE_REORG_TBS
S2999 SYS_LOB_P8615 USAGE_REORG_TBS
S3000 SYS_LOB_P8617 USAGE_REORG_TBS
S3001 SYS_LOB_P8619 USAGE_REORG_TBS
S3004 SYS_LOB_P8621 USAGE_REORG_TBS
S3005 SYS_LOB_P8623 USAGE_REORG_TBS
S3006 SYS_LOB_P8625 USAGE_REORG_TBS
S3007 SYS_LOB_P8627 USAGE_REORG_TBS
S3008 SYS_LOB_P8629 USAGE_REORG_TBS
S3009 SYS_LOB_P8631 USAGE_REORG_TBS
S3010 SYS_LOB_P8633 USAGE_REORG_TBS
S3011 SYS_LOB_P8635 USAGE_REORG_TBS
S3012 SYS_LOB_P8637 USAGE_REORG_TBS
S3013 SYS_LOB_P8639 USAGE_REORG_TBS
S3014 SYS_LOB_P8641 USAGE_REORG_TBS
S3015 SYS_LOB_P8643 USAGE_REORG_TBS
S3050 SYS_LOB_P8645 USAGE_REORG_TBS
SMAXVALUE SYS_LOB_P8647 USAGE_REORG_TBS
32 rows selected.
SQL> select TABLE_NAME,COLUMN_NAME,SEGMENT_NAME,TABLESPACE_NAME,INDEX_NAME,PARTITIONED from user_lobs where TABLE_NAME in ('TRB1_PUB_LOG','TRB1_SUB_ERRS','TRB1_SUB_LOG') ;
TABLE_NAME COLUMN_NAME SEGMENT_NAME TABLESPACE_NAME INDEX_NAME PAR
TRB1_SUB_ERRS GENERAL_DATA_C SYS_LOB0006703055C00017$$ TRBDBUS1LNN1 SYS_IL0006703055C00017$$ YES
TRB1_SUB_LOG GENERAL_DATA_C SYS_LOB0006703157C00017$$ TRBDBUS1LNN1 SYS_IL0006703157C00017$$ YES
TRB1_PUB_LOG GENERAL_DATA_C SYS_LOB0006702987C00014$$ TRBDBUS1LNN1 SYS_IL0006702987C00014$$ YES
SQL> SQL> select unique segment_name ,tablespace_name from user_Segments where segment_name in (select SEGMENT_NAME from user_lobs where TABLE_NAME in('TRB1_PUB_LOG','TRB1_SUB_ERRS','TRB1_SUB_LOG') );
SEGMENT_NAME TABLESPACE_NAME
SYS_LOB0006702987C00014$$ USAGE_REORG_TBS
SYS_LOB0006703055C00017$$ USAGE_REORG_TBS
SYS_LOB0006703157C00017$$ USAGE_REORG_TBS
SQL> select unique segment_name ,tablespace_name from user_Segments where segment_name in (select INDEX_NAME from user_lobs where TABLE_NAME in('TRB1_PUB_LOG','TRB1_SUB_ERRS','TRB1_SUB_LOG') );
SEGMENT_NAME TABLESPACE_NAME
SYS_IL0006702987C00014$$ USAGE_REORG_TBS
SYS_IL0006703055C00017$$ USAGE_REORG_TBS
SYS_IL0006703157C00017$$ USAGE_REORG_TBS
SQL> select unique index_name,def_tablespace_name from user_part_indexes where table_name in ('TRB1_PUB_LOG','TRB1_SUB_ERRS','TRB1_SUB_LOG');
INDEX_NAME DEF_TABLESPACE_NAME
SYS_IL0006702987C00014$$ TRBDBUS1LNN1
SYS_IL0006703055C00017$$ TRBDBUS1LNN1
SYS_IL0006703157C00017$$ TRBDBUS1LNN1
TRB1_PUB_LOG_PK USAGE_REORG_IX_TBS
TRB1_SUB_ERRS_1IX USAGE_REORG_IX_TBS
TRB1_SUB_ERRS_1UQ USAGE_REORG_IX_TBS
TRB1_SUB_ERRS_2IX USAGE_REORG_IX_TBS
TRB1_SUB_LOG_1IX USAGE_REORG_IX_TBS
TRB1_SUB_LOG_PK USAGE_REORG_IX_TBS
SQL> select unique def_tablespace_name from user_part_tables where table_name in ('TRB1_PUB_LOG','TRB1_SUB_ERRS','TRB1_SUB_LOG');
DEF_TABLESPACE_NAME
USAGE_REORG_TBS
Please let me know if some more details required.>whereas user_lobs and user_part_indexes shows me different information regarding tablespace.
do you see different results after starting a new session after the ALTER statements were issued? -
Moving sys.aud$ to a different tablespace other than system
Hi,
I have a 10g RAC database system with a high volume of activity and would like to monitor a large slice of it using audit.
I have reviewed all options of audit trails and chose db, extended to be the most suitable for my purposes!
Ive noticed that all audit data goes to sys.aud$ table in system tablespace.
I have 3 questions:
1. What is the logic behind putting this table in systems tablespace and not sysaux (10g)?
2. Can I move sys.aud$ table to a different tablespace (should I expect trouble for doing so)?
3. Is there any RAC implication if I move sys.aud$ table to a different tablespace?
Regards,
Tal Olier
[email protected]That's true, it's not recommanded to move a sys table... but we can find some good explanation for this one for aud$ table.<br>
See Metalink Note 72460.1 : Moving AUD$ to another tablespace and adding triggers to AUD$<br>
Or google search give some good results.<br>
Nicolas. -
Assign AW to a different tablespace
Hello all,
We would like to move an analytical workspace (Oracle 10.2.0.1) to a different tablespace. The owner user was originally assigned to a shared tablespace; however, it was changed to use a dedicated tablespace. I have attempted to export / import the AW upon the change, but it is still assigned to the original shared tablespace. Could you please let me know how to change the tablespace, so I don't have to recreate the AW from scratch.
Many thanks!If I read this correctly, you have an existing AW that you want to move to a different tablespace. If so, you will need to recreate your AW. The easiest way to do this is as follows:
1. Save dimensions and cubes to XML templates. (Save them independantly, don't just save the AW to a template.)
2. Create a new AW, using the tablespace option. (I recall that there was a bug in 10.x where the tablespace option got ignored. After you create your AW with the spacespace option, check to see which tablespace the AW$ table is in. If it's in the default tablespace, not the tablespace you have chosen, you probably need a patch or upgrade.)
3. Create your dimensions and then cubes from the templates in the new AW. -
Moving partioned tables to different tablespaces in oracle 11g.
Dear All,
I need to move the partitioned table to different tablespace. I moved all the partitions individually and also the index.
however i have a issue now, when i check the view user_tables or dba_tables, i see null tablespaces correspomding to the table in the tablespace_name column.
how can i see the tablespace name in these views.Even thouh Sb has given you the correct answer, I am just showing you below cut and paste sqlplus screen of 11.2.0.1 :
test1@ORCL> create table t (x number)
2 partition by list (x)
3 (partition p1 values (10),
4 partition p2 values (20));
Table created.
test1@ORCL> select table_name,tablespace_name from user_tables;
TABLE_NAME TABLESPACE_NAME
T
1 row selected.
---Means tablespace_name.user_tables is always null for partition table(s).
---Ok, then how do I see the tablespace name?
test1@ORCL> select table_name, partition_name,tablespace_name
2 from user_tab_partitions
3 where table_name = 'T';
TABLE_NAME PARTITION_NAME TABLESPACE_NAME
T P1 USERS
T P2 USERS
2 rows selected.
test1@ORCL> ALTER TABLE T MOVE PARTITION P1 TABLESPACE EXAMPLE;
Table altered.
test1@ORCL> select table_name, partition_name,tablespace_name
2 from user_tab_partitions
3 where table_name = 'T';
TABLE_NAME PARTITION_NAME TABLESPACE_NAME
T P1 EXAMPLE
T P2 USERS
2 rows selected.
test1@ORCL> select table_name,tablespace_name from user_tables;
TABLE_NAME TABLESPACE_NAME
T
1 row selected.Just for your information please.
Regards
Girish Sharma
Maybe you are looking for
-
Error message 'Message no. ME867' while deleting a PO line item
Hi, This is a PO item without material master and account assigned to cost center.GR (101) was done and the GR is cancelled(102)for the total quantity. While deleting the PO line item, i am getting error message with out any description.When i check
-
It seems to me that you can only purchase apps by means of a credit card.If so, I am very disappointed.Are there no other way to purchase apps?
-
Ok so it comes up saying Primary internal battery 601???? but my notbook is like 2 years old how can the battery be dead? can some plz help me out heres he info on my notbook its a hp pavilion dv7 plz any help would be great
-
Hi there.. i bought myself a new mac book pro and deinstalled quicktime.. why is not so important.. stupid thing to do because i tried to install quicktime with the downloaded quicktime for leopard 7.5 and it says this "software is not meant for this
-
H.264 streaming in flash player motion blur
Hi , We are using H.264 for live streaming in a flash window . The encoding works fine but when there is alot of fast movement on the stream there is a degradation in the quality of the video. When the fast movement stops the video restores itself bu