SQL & PL/SQL :: Add Index Enable No Validate

Nov 1, 2011

I have a table, it has 3 terabytes of data. We are sure whatever the data we have in that table is valid. I need to add the index to table it should be enabled and need not to be validated for existing data.

I am using following command

CREATE INDEX U_IXN_MTRS_ORGIDMTRNOMTRTYPEID ON MTRS (nlssort(METERNO), METERTYPEID) TABLESPACE OLTP_IDX_TS ENABLE NOVALIDATE;

it is giving me problem

ORA-02158: invalid CREATE INDEX option error

View 4 Replies


ADVERTISEMENT

SQL & PL/SQL :: Enabling Constraint With Enable No Validate?

Sep 5, 2013

Is there any way to enable the constraint with out validating for the existing information.

As We can accomplish the same functionality when we are adding the constraint for the first time.

Ex: alter table scott.emp add constraint fk_deptno foreign key(deptno) references scott.dept(deptno) enable novalidate

The above SQL statement will enable the constraint with out validating for the existing information. So there is possibility of data will be there only in the child table but not in the parent table for existing information.

But in the future it will not allow to do so,if the constraint is in ENABLE staus.So i am just trying to disable the constraint to insert only into child table & trying to enable it with NOVALIDATE option .

But the following exception is coming .

SQL> alter table scott.emp ENABLE constraint fk_deptno enable NOVALIDATE;

alter table scott.emp ENABLE constraint fk_deptno enable NOVALIDATE

ORA-00905: missing keyword

SQL> alter table scott.emp ENABLE constraint fk_deptno NOVALIDATE;

alter table scott.emp ENABLE constraint fk_deptno NOVALIDATE

ORA-00933: SQL command not properly ended

Instead of dropping & recreating the same constraint , is there any alternate way to do this ?

View 3 Replies View Related

Server Administration :: Validate Structure Of Index

Jan 5, 2012

I am working on Index issue and need to validate the structure of the index. Does validation lock the Index ?

Do we need downtime or we can do it in normal working hours.

alter index index_name validate structure;

View 9 Replies View Related

Text :: Index For Domain Index With Composite Domain Index (CDI) Very Slow

Jun 27, 2012

I am on 11.2.0.3 Enterprise Edition. We are using the new feature "Composite Domain Index" for a Domain index on a very large table (>250.000.000 rows). It really works with mixed queries. We added two number columns using FILTER BY.We have lots of DML on this table. Therefore, we are executing synchronize and optimize once the week. The synch behaves pretty normal. But "optimize_index" takes a very very long time to complete. I have switsched on 'logging' for the optimize process. The $I table takes some time but is finished normally. But the optimization of the $S table (that is the table created for the CDI feature) is running over 12 hours now - and far from being finished. From the logfile, I can see that it optimizes 1000 rows every 20 minutes. Here is the output of the logfile:

Oracle Text, 11.2.0.3.0
14:33:05 06/26/12 begin logging
14:33:05 06/26/12 event
14:33:05 06/26/12 process $N for optimize: SEQDEV.GEN_GES_DESCRIPTION_CTX_I
14:33:16 06/26/12
14:33:16 06/26/12
[code]....

I haven't found a recommendation from Oracle not to use "optimize_index" for Domain Indexes with CDI. But in my case, it would be much faster just to drop and recreate the Domain Index in question.

View 5 Replies View Related

Performance Tuning :: Local Index Versus Global Index On Partitioned Table

Jun 28, 2011

I have a huge table (about 60 gb) partition over range. The index on this table is global index created on 4 columns together. I have a query which is running very slowly. The explain plan is showing the use of this global index.Explain plan is not showing pstart and pend because the index is global.

View 6 Replies View Related

Server Administration :: Convert Global Index To Local Index

Jun 23, 2011

I have a global index and I want to convert it to local index.Is there a way to recreate local index with out dropping the global index.

I can create a local index first and then drop the global index. But is there a way to create it with out dropping the global index, just convert it.

View 5 Replies View Related

SQL & PL/SQL :: ORA-01502 - Index Or Partition Of Such Index Is In Unusable State?

Nov 29, 2010

I am facing the error "ORA-01502: index or partition of such index is in unusable state " while loading the text data using
sql loader with direct path (direct = Y ,rows = 10000) option. Table consists an composite non unique index. If I query the dba indexes for the effected index it shows the index status as VALID. There was no maintaince done on the effected table or index. I have tried loading the same data using conventional path but didn't found any issues for the same.

View 3 Replies View Related

Performance Tuning :: Index With NVL / Query Is No Longer Using Index

Nov 19, 2010

I have a query which had a join:

a.c1=b.c1 and a.c2=@var

where @var is user supplied input at runtime...We had a index on a.c2 . The CBO would use this index to generate an opitimised query plan.We found some records from table "b" were dropping due to inner join. So we made a change in join. It'd be like

a.c1(+)=b.c1 and nvl(a.c2,@var)=@var

This query is no longer using the index, instead its doing a full table scan causing the query to slowdown.I have tried creating index on nvl(a.c2,'31-dec-9999')

But the CBO won't use it.Anyway to create index on this col so that full table scan can be avoided?

View 2 Replies View Related

Performance Tuning :: Force Index If Table Not Using Index?

Aug 9, 2013

How to force an index if the table not using the index?

View 10 Replies View Related

When Index Lock Contention Occurs / How To Know Which Index Is Causing

Aug 27, 2012

We have occurrences of enq : TX - index contentions in the database. Using the SQL ID, we have identified the INSERT statement and the table which they are trying to insert.

This table has almost 25 different indexes, some of which are unique as well.I am wondering how to identify the actual index causing issue, out of these 25 indexes.

Is there any way to pin point to the name of index which is causing the lock?My plan is, once the index is identified, I would like to check the extents and inittrans and other attributes of this index to fix.

View 5 Replies View Related

SQL & PL/SQL :: Enable To Run Procedure Through Job?

Mar 30, 2011

I am trying to execute procedure using dbms scheduler.but i am getting below errors

ORA-06550: line ORA-06550: line 1, column 407:
PLS-00103: Encountered the symbol "AMANORATEST" when expecting one of the following:
:= . ( @ % ; immediate
The symbol ":=" was substituted for "AMANORATEST" to continue.
, column :

but procedure is executing fine with sql commmand line.

View 1 Replies View Related

SQL & PL/SQL :: Enable Row Movement On IOT?

Nov 11, 2011

I have the table is partitioned.

Can I set the table table to "alter table x enable row movement" even when it is index organized table?

How do I know if the table is INDEX ORGANIZED TABLE.

View 3 Replies View Related

SQL & PL/SQL :: Create Non-cluster Index On A Clustered Index?

Jul 11, 2012

Can we create non-cluster index on a clustered index?

View 5 Replies View Related

Enable / Disable Auditing From PHP

Dec 15, 2010

In PL/SQL Plus, i can enable/disable auditing when i connect as sysdba by using these command:

SQL> ALTER SYSTEM SET audit_trail=db SCOPE=SPFILE
SQL> shutdown
SQL> startup

I've done it successfully with PL/SQL Plus command line. But in PHP, how can i do that?How to execute "shutdown" and "startup" from PHP?
I've found this code for connect to oracle as sysdba:

oci_connect("/", "", null, null, OCI_SYSDBA);

From the following link:

[URL]......

But, i still can't execute "shutdown", "startup";

View 4 Replies View Related

Unable To Enable The Audit

Jul 5, 2012

I facing the below issue while enable the audit on table.

SQL> audit delete on test;
audit delete on test
*
ERROR at line 1:
ORA-00604: error occurred at recursive SQL level 1
ORA-01400: cannot insert NULL into ("SYS"."AUDIT_DDL"."DICT_OBJ_TYPE")
ORA-06512: at line 2

===
Related Information
===
SQL> select version from v$instance;

VERSION
-----------------
11.2.0.2.0

SQL> show parameter audit;

NAME TYPE VALUE
------------------------------------ ----------- ------------------------------
audit_file_dest string /orasw/product/11.2.0
/rdbms/audit
audit_sys_operations boolean FALSE
audit_syslog_level string
audit_trail string DB

SQL> SELECT TABLESPACE_NAME,owner from dba_tables where table_name='AUD$';

TABLESPACE_NAME OWNER
------------------------------ ------------------------------
AUDIT_DATA SYS

View 4 Replies View Related

Application Express :: 4.1.1.00.23 - How To Enable SSP

Feb 20, 2013

I have Apex 4.1.1.00.23 and I want enable Session State Protection (just for testing and for learning how this works).

When I go to Home --> Application Builder --> Application 121 --> Shared Components --> Session State Protection and I click Set protection button I get to the page where I have 3 options (Disable, enable and Configure SSP).

After clicking on enable option, I get to page [URL].......

There is no Finish or submit or complete or confirm button, only cancel and previous (print screen is on picture). I found out that SSP is already enabled so I can't enable it again. But other question is still open, how to get it now to work in real.

View 0 Replies View Related

Enable Audit On Database Level?

Aug 27, 2013

1.) Whatever statics/data should we gather to compare the database performance before and after enable the audit on database level?

2.) How can we enable audit on database level?

3.)what is pros and crons of enable audit database level?

View 1 Replies View Related

How To Check If Parallel Enable In Session

Aug 18, 2010

I need to know if PARALLEL is enabled in my session. Would this be a session parameter or something else? Is there a view I have to query or some SQL*Plus command to execute?

P.S. Is there a way to correct the title spelling after submitting.

View 3 Replies View Related

Security :: How To Enable Auditing In Oracle

Dec 8, 2011

How to enable auditing in oracle ?

View 2 Replies View Related

SQL & PL/SQL :: How To Disable Or Enable All Constraints In A Table

Apr 8, 2010

I knew, how to enable or disable a constraint on a table.

>alter table <table_name> disable constraint <constraint_name>;

But if we know all the data is correct, it's better to disable all constraints to improve the performance.

We are allowed to Disable or Enable only a single constraint.

Enable or Disable All Constraints.

View 11 Replies View Related

Performance Tuning :: How To Enable AWR In Oracle 10g

Jul 12, 2013

I have installed database in one server. I would like to enable AWR into it. Statistics_level is set to Typical. While running the below script to enable the AWR, its gives error -

SQL> exec dbms_scheduler.enable('GATHER_STATS_JOBS');
BEGIN dbms_scheduler.enable('GATHER_STATS_JOBS'); END;

*
ERROR at line 1:
ORA-27476: "SYS.GATHER_STATS_JOBS" does not exist
ORA-06512: at "SYS.DBMS_ISCHED", line 4343
ORA-06512: at "SYS.DBMS_SCHEDULER", line 2802
ORA-06512: at line 1

make AWR automatical generation.

View 3 Replies View Related

Server Administration :: Enable Row Movement?

Jul 3, 2012

I have a job that runs the following commands for each table in a schema.. (I just inherited it ugggg)

alter table ODS.ODS_MONTHLY_MF_AUM enable row movement;
alter table ODS.ODS_MONTHLY_MF_AUM shrink space;
alter table ODS.ODS_MONTHLY_MF_AUM disable row movement;

On occassion I get this error when enabling row movement

ERROR at line 1:
ORA-00054: resource busy and acquire with NOWAIT specified

Other than dealing with apps that depend on ROWID's is there any negative impact to always keeping row movement enabled for tables.

Secondly, does any body have a script that can determine if the space really needs to be shrunk for a table.

View 13 Replies View Related

SQL & PL/SQL :: How To Enable NOLOGGING In External Tables

Jun 16, 2011

How can I enable NOLOGGING in an External Table ?

My Table FT_PRICE_COST_MASTER is taking a long time(more than 1 hour) to excute inside the procedure. The statement is:

SELECT SUBSTR(m.sr_no,1,16) SR_NO, m.SKU_CODE, m.location_code, m.start_date, m.end_date, m.COST, m.tax, m.octroi, m.freight, m.cash_disc, m.scheme_disc, m.mrp, m.csp, m.rsp1_qty, m.rsp1_value, m.rsp2_qty, m.rsp2_value, m.rsp3_qty, m.rsp3_value, m.net_cost, m.final_cost, m.current_margin, m.pc_effect, m.created_by, m.creation_date, m.modified_by, m.modification_date, m.change_ind, m.tax_code,
[code]......

When I am recreating the External table with NOLOGGING keyword at the bottom of the synatx, it's showing "operation not supported". Else are there any other points that I should look to increase the execution time of the above statement ?

View 2 Replies View Related

Security :: Enable Auditing For Users?

Oct 10, 2012

i enable auditing on the database 10.2 for users,

once i query SQL> SELECT username,
extended_timestamp,
owner,
obj_name,
action_name
FROM dba_audit_trail
WHERE owner = <Username>

there are many many rows , my question is , are you enable to truncate it from time to time , if not ,is it effect on the performance of the database ?

View 3 Replies View Related

PL/SQL :: Enable Dbms_job To Run On Every Day At 4am Excluding Fridays?

Jun 7, 2013

how to enable dbms_job to run on every day at 4am excluding Fridays.

View 7 Replies View Related

SQL & PL/SQL :: How To Make PK Not To Validate

Nov 21, 2011

i am writing a script for inserting rows in a table where primary key of that table consists of 4 columns. I want to add a new row where 3 columns of that table will be same but change the value of the last one. this is giving an error saying that i am violating the unique constraint. I tried to disable that constraint/PK by following statement but still this error is coming

alter table sections_budgets modify primary key disable cascade;

OR

alter table sections_budgets modify constraints sec_bdgt_pk disable cascade;

the insert statement which i am using. The first four columns are part of PK

insert into sections_budgets (SELECT sb.bdgt_cd, sb.bdgt_dpf_cd, sb.bdgt_yr, :sec_code, sb.usf_usr_id,
sb.aty, sb.comaty, sb.comytd, sb.expn_ytd, sb.sys_dt, sb.cat,
sb.start_aty, sb.expn_lmt
FROM sections_budgets sb
WHERE sb.bdgt_dpf_cd = :b_d_code AND sb.bdgt_yr = :year);

is there any other way of inserting records in this table without droping the whole table because it contains too many triggers and constraints?

View 24 Replies View Related

How To Validate SQL Scripts

May 7, 2013

How to Validate SQL scripts?

I am having set of sql files i wish to run one by one if there is any error at one file i need to notify to the user.I have created Bat file in-order to execute in a sequence.how to validate in bat file

say

01.sql ---Sucess
02.sql --- Fail -- intimate and not to execute rest of sql files
03.sql
04.sql

View 34 Replies View Related

How To Validate SQL Run On Database

Feb 26, 2013

We are looking for validating our product upgrade changes. As part of product upgrade, there will be changes to the schema.

Like addition of tables, addition of columns to existing tables, change the length of character columns, add new index, etc. We want to verify on the database, that these SQL are run successfully on the database.

Is there a table/view, that can be queried to figure out whether such sql was run and the status of the execution, after some time (day or two) after these are actually run on the database.

View 4 Replies View Related

RAC & Failsafe :: Enable Audit_trail On 2 Node RAC ENV On Oracle10g

Nov 23, 2011

I have a production database with 2 node Physical RAC ENV on two separate machines , and we are going to enable audit trail parameter to DB values to capture all failed login attempts on a database.

we have done this on our testing ENV but dont know the procedure to deploy this steps on 2 node RAC ENV . I have done the below steps on our standalone testing ENV

1.Log in as SYS and connect with the SYSDBA privilege.
oUser Name: SYS
oPassword: Enter your password.
oConnect As: SYSDBA

2.To enable audit on DB use below command
SQL>alter system set audit_trail=DB scope=SPFILE;

3.Then restart the database.

4.After successful startup use the below command to capture log
SQL> audit create session whenever not successful;

steps to enable audit_trail to capture failed login attempts on two node RAC ENV.

View 4 Replies View Related

Client Tools :: How To Enable Profiler In Toad

Oct 2, 2010

I'm using toad 9.2.7.5 to do my plsql development. How I can enable the Profiling option so that I can analyse the performance of my stuff - currently the grey profiler icon is greyed out

View 1 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved