SQL & PL/SQL :: Difference Of Unique And Range Scan

Mar 11, 2010

diff of unique scan and range scan?

View 1 Replies


ADVERTISEMENT

Performance Tuning :: Row ID Range Scan

Dec 19, 2011

I want to make full table scan of my query so that I can execute it using parallel option & the query will get completed in few mins. Even though I used this hint "/*+ parallel(t2,4) full(t2) */, the query is executing with 8 parallel processes but it is going for "Rowid Range Scan" and it is taking more time to complete. How to make this query to go for full table scan instead of "Rowid Range Scan" so that this query can be tuned.

SELECT /*+ parallel(t2,4) full(t2)*/ID, COUNT (1) FROM acnt_transact t2 GROUP BY ID;

View 9 Replies View Related

Performance Tuning :: Force Index Unique Scan?

Jun 14, 2012

Is there any hint to force "Index Unique Scan" over "Index Range Scan".

My query is generating different plans with the above two, and very slow when it uses "Index Range Scan".

View 19 Replies View Related

Performance Tuning :: How To Force SQL To Use Index Range Scan

Jul 15, 2011

How can i force a sql use index range scan?

View 10 Replies View Related

Performance Tuning :: How To Keep RANGE SCAN Even After Adding New Conditions

Aug 29, 2011

I am adding condition in color to my existing query but my query taking too long time after that. This condition calculates last 3 month end dates from given COB (20110516).

SUMMARY is my summarized table and COB is my reference table

Without adding condition in query it gives
INDEX (RANGE SCAN)--PK_SUMMARY(INDEX(UNIQUE))
After adding condition in query it gives
INDEX(FAST FULL SCAN)--PK_SUMMARY(INDEX(UNIQUE))

how can i keep RANGE SCAN even after adding my new conditions?

SELECT
distinct
COB.COB_ID_C,
SUMMARY.SUMM_COB_ID_C
FROM

[code]...

View 4 Replies View Related

PL/SQL :: Number Range Query Causes Repeated Scan By Index

Oct 16, 2012

I have a query that seems to repeatedly call an index scan on a table for reasons I'm not sure about. Why it would be doing the index scan on totaldwellingarea in the dimensions table (DIMEN_PID_TDWELLAREA) repeatedly? This only seems to happen when I put on the range clause d.totaldwellingarea between scr.lowvalue and scr.highvalue.

I am using Oracle version 9.2.0.3.

select d.propertyid,d.totaldwellingarea, e.size_,  scr.size_
from  eqid e, dimensions d,  brt_eval.size_code_ranges scr
where e.style not in ('1','A','G','L') and e.size_  = '0'
and d.propertyid = e.propertyid and e.style = scr.style and d.totaldwellingarea between scr.lowvalue and  scr.highvalue;

CREATE
  TABLE "BRT_ADMIN"."EQID"
  (
    "PROPERTYID"   VARCHAR2(20 BYTE) NOT NULL ENABLE,
    "EQID"         CHAR(10 BYTE),
    "ZONE_"        CHAR(1 BYTE),
    "AREA"         CHAR(1 BYTE),
[code].....

View 3 Replies View Related

Performance Tuning :: How To Verify If A Row Exists (index Range Scan)

Oct 18, 2011

In the link below [URL] Thomas kyte has said, use the CBO and select /*+ FIRST_ROWS */ primary_key from table where rownum = 1; it'll read the index and stop at the first row. very fast on a big empty table (as the index is small and empty).

very fast on a big full table as the index is just read to find the first leaf node and then "stop".

It gives faster result if the primary key is used. But what if we have a table with around 1000 million rows and for the predicates there is a index range scan on the table.

What if we have a table say big_table (10000000000 rows) and the sql is something like

select /*+ first_rows */ 1 /* id, attribute_id*/
from big_table
where attribute_name ='Gross Premium'
and value ='10000'
and version_date is null
and rownum=1; --it's taking around 3 min

We observed that in such case there will be a range index scan for the index on the predicates. For a particular id there may be different values for attribute 'Gross Premium' and may have multiple versions.

How I would tune such a query where the purpose is to check if at least 1 records exists in the table for the input?

View 4 Replies View Related

SQL & PL/SQL :: Difference Between Primary Key And Unique / Not Null

Dec 10, 2010

what is difference between primary key and unique+not null

View 12 Replies View Related

Real Application Clusters :: Reallocate Scan Listener And Scan Vip In 3 Node Rac?

Apr 9, 2013

We are using oracle 11.2.0.3.0 with 3 node rac. Earlier 3 scan vip and 3scan listener running on each node.But we found recently node1 running using 2vip and 2scanlistener and in node2 1vip and 1scanlisteners were running.but no longer running scan vip or scan listener in node 3. If i decided to reloacate the scan vip/Scan_listener to node3 from ndoe 1 using below command,does it cause any impact on my transcation?

$ srvctl relocate scan -i 2 -n node03
$ srvctl relocate scan_LISTENER -i 2 -n node03

find the below details

$ bash
bash-4.2$ srvctl status scan
SCAN VIP scan1 is enabled

[Code]....

View 12 Replies View Related

PL/SQL :: Index Range Scan And Table Access By Index Rowid Versus Table Access Full

Oct 5, 2013

Let's consider such table that all rows fit into single block:

SQL> create table test as select rownum id, '$'||rownum name from dual connect by level <= 530;
Table created.
SQL> create index i_test on test(id);
Index created.
SQL>
SQL> begin

[code].....

why does approach with full scan take longer even if table occupies only one data block? PS. 11gR2

View 8 Replies View Related

PL/SQL :: Date Difference - Include Both Start And End Date In Range

Aug 8, 2013

select to_date('28-FEB-2013') - TO_DATE('01-FEB-2013')  FROM DUAL 

gives me 27 days, what should I do to get 28 ? meaning include both the start and end dates in the range ?

View 3 Replies View Related

Non Unique Index Using A Non Unique Field

Aug 14, 2013

Using Oracle 11g, below is the table, partitions, unique and non-unique local index: 

CREATE TABLE DOCA(  DOCA_ID  NUMBER  NOT NULL ,  DOCA_BKG_PAX_ID  NUMBER  NULL ,  ROW_PURGE_DATE  DATE  NULL ,)PARTITION BY RANGE(ROW_PURGE_DATE)INTERVAL(NUMTOYMINTERVAL(1, 'MONTH'))(  PARTITION P2007 VALUES LESS THAN (TO_DATE('01/01/2008', 'dd/mm/yyyy')),  PARTITION P200801 VALUES LESS THAN (TO_DATE('01/02/2008', 'dd/mm/yyyy')),)  TABLESPACE T0; ALTER TABLE DOCA ENABLE ROW MOVEMENT;    

CREATE UNIQUE INDEX XPKDOCA ON DOCA(  DOCA_ID  ASC,  ROW_PURGE_DATE ASC)LOCALREVERSE TABLESPACE I0;  ALTER TABLE DOCA  ADD CONSTRAINT  XPKDOCA PRIMARY KEY (DOCA_ID);    CREATE INDEX XFKDOCA_DOCA_BKG_PAX_ID ON DOCA(  DOCA_BKG_PAX_ID  ASC)LOCALREVERSETABLESPACE I0;  

I would like to know the difference between the performance of the unique and non-unique local indexes?.

View 10 Replies View Related

Scan In 4 Node Cluster

Jun 24, 2013

We are going to setup a 4 node rac cluster. So i think we need to configure only one SCAN with 3IP's. And how the scan listeners are configured on these 4 nodes.

View 1 Replies View Related

RAC & Failsafe :: SCAN IP For Oracle 11g R2?

Sep 1, 2011

I am planning to install oracle RAC 11g R2 on RHEL 5.3. I have 2 RAC nodes and one openfiler NAS. I need to understand how will I configure SCAN IP. Do I need to configure it some where in DSN and OS level or just I need to give this IP and SCAN name while grid install and oracle will create these things?overall steps to configure this or direct me to some documentation where this thing is detailed.

View 6 Replies View Related

Table Scan From The Application?

May 21, 2013

We have an application where delete statement is taking a long time ( 30-40 seconds).v$session_longops shows the sql statement is doing a full table scan. The statement is "delete tablename where column_name =:B1". The table is indexed and the indexed column is being used in the where clause. When I do an explain plan on the same statement with a value for column_name, it uses an index scan. The table has 9 million rows and the delete statement deletes 15 rows. Not sure why SQL when running through the application does not use index. The stats are current.

View 11 Replies View Related

Local Index Scan

Nov 17, 2012

if i have local index, does query which uses this index always have to scan all partitions?

For example, I have hash-partitioned table on column A. There is local index on column B. I am querying:

select * from my_table where A='ABC' and B>123.

I know that records with A='ABC' are in 2nd partition. Does only 2nd partition of local index will be scanned or all of them must be scanned?

View 1 Replies View Related

PL/SQL :: Calculate Difference By Which Day Count Of Difference Is Going?

Oct 17, 2012

Detail table will look like below:

Product_id issue_date action_date Force_date
1 10/10/2012 10/10/2012 10/10/2012
2 10/10/2012 10/10/2012 10/10/2012
3 10/10/2012 13/10/2012 15/10/2012
[code]....

Need the data like

Issue_date count_action_date count_Force_date (diff(action_date,force_date) 1 2 3 4 5 6(days since over)

10/10/2012 3 4 1 4 2 1 0 0

How to get the data like this? automatically how to get 123.... and how to calculate the difference by which day the count of difference is going?

View 3 Replies View Related

Getting Query To Do Full Table Scan?

Aug 18, 2012

I�m Using Oracle 11.I have a table with 16 million rows and an index (let's call it the employee table with an index on department). I need to select all the employees whose departments are located in the uk. I achieve this by selecting all the department numbers from departments where location = 'UK' in a sub select then plug this into the main query as follows:

SELECT *
FROM employees
WHERE department IN (SELECT department from departments where location = 'UK');

It takes ages, 25 seconds or more, the explain plan shows its doing a full table scan on emplyees. I need it to use the index. The sub query is instant and returns only 5 rows. If I explicitly put the 5 numbers in the IN clause the query uses the index and executes in 0.04 seconds. See below:

SELECT *
FROM employees
WHERE department IN (1,2,3,4,5);

I need it to use the subquery once and then use the index on the main table.

View 2 Replies View Related

Forms :: How To Scan Pics Using Oracle

Jul 8, 2012

I need to create a form that will enable me to scan pages and save it into a specified folder using the scanner connected to the PC.

View 1 Replies View Related

Forms :: Image Scan In Oracle 6i?

Sep 19, 2010

scan image from Oracle Form Builder 6i and store the image location in the oracle 9i database. Here important issue is we just store the image location in the database not the image. We'll store the images in a storage device and store the location path in the database. And retrive the image from storage device using the path.

For example: User Scan the image using Form builder 6i then save the image like 1001-DPS-1.jpg in the default location like D:Image.. And in oracle 9i database data save like : 1001 DPS 1 D:Image1001-DPS-1.jpg User_Name Sysdate

Data save automatically in the database when image scanned and saved in physical drive. This is our main purpose.

Is it possible to solve this task using Oracle 9i and Developer 6i?

View 2 Replies View Related

Enterprise Manager :: Why Scan Address Used In OEM

May 1, 2012

I am an OEM Gird Control 11g server with Oracle 11.2.0 running on OEL 5.3

I also have 2 node RAC cluster running Oracle 11.2.0 on OEL 5.3. I have installed OEM Agent on nodes of this cluster. I can see them on OEM Grid Console. When I check the configuration of the Database Instance GTRD1 (one of my target instance)I can see that the "Listener Machine Name" is the management IP address of target database server. Similarly Database Instance GTRD2 has the management IP address of target database server. When I click test conenctions it works. This is without entering any reference to this server/IP address in /etc/hosts file.

But when I select targets->all targets->Database Instance GTRD1 and then try to access performance tab, it does not connect. I get this error "The Network Adapter could not establish the connection"

Looking at the "emoms.trc" I find the follwing

2012-04-30 14:02:12,071 [EMUI_14_02_12_/console/database/instance/sitemap] ERROR perf.sitemapPerfChart logp.251 - java.sql.SQLException: The Network Adapter could not establish the connection

The Connect Descriptor was (description=(address=(host=GTRD-scan.GTRD)(protocol=tcp)(port=1521))(connect_data=(service_name=GTRD1)(instance_name=GTRD1)(UR=A)))java.sql.SQLException: The Network Adapter could not establish the connection

The Connect Descriptor was (description=(address=(host=GTRD-scan.GTRD)(protocol=tcp)(port=1521))(connect_data=(service_name=GTRD1)(instance_name=GTRD1)(UR=A)))

But when I enter the scan address in the /etc/hosts as "112.5.14.154 GTRD-scan.GTRD" Then everythign work works.
NOTE: 112.5.14.154 is GTRD1 server and 112.5.14.155 is GTRD2 server

Now my questions are:
1. Do I must enter scan address/ref "GTRD-scan.GTRD" in /etc/hosts?
2. Is there are way to change it to use hostname or the IP address?
3. If I am to use scan address, then how I refer to the other IP address in hosts file?

View 1 Replies View Related

RAC/ASM Clusterware Installation :: Can SCAN IP Be Used For Ftp Of Files

Sep 25, 2013

I would like to know, if SCAN IP can be used by clients or applications to FTP files to either of the database nodes? 

View 3 Replies View Related

Use Scan Name In Tnsfile - Not Able To Connect To DB Through JDBC Connection?

Aug 4, 2010

I have installed 2 node RAC -11gR2 on ORACLE VM Server 2.2.1.now, I want to give tnsentry to my dev team to use this RACDB going forward.I am using scan name in tnsnames.ora file. Also I have make scan name entry in /etc/hosts not in the DNS.

I have below entry in RACDB server...
RACDB =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = RWCORA-cluster-scan)(PORT = 1521))
(CONNECT_DATA =
(SERVER = DEDICATED)
(SERVICE_NAME = racdb)
)

now just for testing purpose, I added this tnsentry in my machine to check the connectivity.I have to add scan name with IP address in /etc/hosts --. and try to connect sqlplus sys@rwcdb as sysdba --> not workingI have to add scan name with IP address , and two RAC VIPs (of both nodes) in /etc/hosts -- and try to connect sqlplus sys@rwcdb as sysdba --> then its working...but again SQL*Developer is not able to connect.

I have make below entry in my machine's /etc/hosts file:

10.40.0.51 RWCORARAC1-vip
10.40.0.52 RWCORARAC2-vip
10.40.0.50 RWCORA-cluster-scan

perfect link through which I can connect OCI, JDBC connection from client side.

View 4 Replies View Related

Forms :: Scan Image From Oracle 10g By Using Scanner?

Dec 11, 2012

i need scan image from oracle forms 10g by using scanner.

View 2 Replies View Related

Server Administration :: Use CSSCAN To Scan Through Database

Mar 18, 2012

Since the past, our developer uses this command

"update props$ set value$ set = 'ZHS16GBK' where name='NLS_CHARACTERSET' ;" and
update props$ set value$='WE8MSWIN1252' where name='NLS_CHARACTERSET';
to update the sys table which is not supported by oracle.

However, I decided to use CSSCAN to scan through the database and see if the new character set will work.But before using CSSCAN, I will like to know which character set to set back as our developer does not know which is the original character set.

View 8 Replies View Related

Real Application Clusters :: ONS Configuration For Scan?

Oct 4, 2012

We have java application which uses the ons configuration. Currently app's ons nodes parameter is pointing to vip i.e Node1-vip:6200,Node2-vip:6200. Will Ons nodes parameter support the RAC scan? Can i change to Nodes:RAC-scan:6200?

View 1 Replies View Related

Forms :: FRM-41344 OLE Not Defined For SCAN In Current Record

Jun 1, 2010

my problem is this that i have developed a form.fmb in 6i for images scanning direct from scanner but its generating error something like that "FRM-41344 OLE not defined for SCAN in the current record"

li have a winxp enviroment i have already downloaded and installed "IMAGING FOR WINDOW"(GLOBAL 360) but despite this its not working same error is still there .

one more thing why imgscan.ocx is not registering in winxp.

View 3 Replies View Related

Real Application Clusters :: Password For Scan Listener

Aug 17, 2012

How to set the password for SCAN listener in 11gr2 ?

View 9 Replies View Related

Rebuild Local Index Partition Is Using Full Table Scan

Apr 23, 2012

I am rebuilding some UNUSABLE local index partitions on Oracle 8.1.7.4.0 (64bit) database . The platform is a HPUX machine.

The DDL of the partition table/indexes:
=========================
CREATE TABLE TESTME
( INST_NO CHAR(3) NOT NULL,
ACCT_NO CHAR(16) NOT NULL,
REC_NO CHAR(9) NOT NULL,
TRAN_TYPE CHAR(2) DEFAULT ' ',
STAT CHAR(2) DEFAULT ' ',
[code]...

View 2 Replies View Related

Performance Tuning :: Full Table Scan - Query Without Where Clause?

Jul 11, 2013

Below query is degrading the performance of database. As we know that, without where clause, query do full table scan.Now, it is written to generate the sequence no.

SQL> explain plan for
2 SELECT NVL(MAX(P.NUM_SERIAL_NO), 0) + 1 FROM CNFGTR_IRDA_ENVELOPE_DTLS P
3 /
Explained.
SQL> select * from table(dbms_xplan.display());
PLAN_TABLE_OUTPUT
----------------------------------------------------------------------------------------------------
Plan hash value: 3345343365
------------------------------------------------------------------------------------------------
| Id | Operation | Name | Rows | Bytes | Cost (%CPU)| Time |
------------------------------------------------------------------------------------------------

[code].....

Index is not created on the column.

View 6 Replies View Related







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