03-18-2009 1:59 PM
Hi SDN,
I had a requirment where i need to create a index in SQLPLUS.
please let me know the transaction code where we will create index in SAP with SQLPLUS.
i need to create index with code like this.
create index z03 on AFRU (fileds) online = ON.
please tell me where we will create this in SAP
03-18-2009 2:00 PM
sap note had provided these steps
For tables larger than 1GB:
You may need a long time to create the index. Database specific options may
be available to accelerate index creation.
When you want to use a database specific method to accelerate index
creations you can use the following method:
1. Create the index on the Development system using transaction
SE11 (ABAP Data Dictionary).
Note the exact name of the created index.
2. Create the index with the exact name on the Quality assurance system
on database level using the database specific tool (see below).
3. After the index is successfully created, transport the index
to the quality assurance system. This will only transport the
ABAP Dictionary information. As the index already exists, it
is not created after the transport.
4. If steps 2. and 3. are successful repeat these steps on the
productive system.
Database specific acceleration possibilites for index creation
Oracle:
Create the index using SQLPLUS with the following command:
create index <index name> on <table name> ( <field1, field2, ...> )
nologging tablespace <tablespace name>
parallel (degree <number>)
storage <storage clause>
..........online;
Replace <index name> by the exact name of the index
Replace <field1, field2, ...> by the fields of the index
Replace <tablespace name> by the tablespace where the index should be
stored
Replace <number> by the number of CPUs you want to use for index
creation
Replace <storage clause> by the storage clause for the index
Please refer to the Oracle handbook for more details.
Edited by: Naresh Nelapatla on Mar 18, 2009 3:00 PM
03-31-2009 7:14 AM