Bad SQL performance, need to advise

I'm having a problem with the following query:

SELECT SHIPMENT_NUM
SHIPPED_DATE
FROM_ORGANIZATION_ID
FROM_ORGANIZATION_NAME
WAYBILL_AIRBILL_NUM
EXPECTED_RECEIPT_DATE
RECEIPT_NUM
EMPLOYE_ID
BILL_OF_LADING
FREIGHT_CARRIER_CODE
PACKING_SLIP
SHIP_TO_LOCATION_ID
SHIP_TO_LOCATION
NUM_OF_CONTAINERS
COMMENTS
SHIPMENT_HEADER_ID
LAST_UPDATED_BY
LAST_UPDATE_DATE
LAST_UPDATE_LOGIN
CREATED_BY
CREATION_DATE,
PROGRAM_APPLICATION_ID
PROGRAM_ID
PROGRAM_UPDATE_DATE
REQUEST_ID
USSGL_TRANSACTION_CODE
GOVERNMENT_CONTEXT
RECEIPT_SOURCE_CODE
ASN_TYPE
VENDOR_SITE
$VENDOR_NAME
ATTRIBUTE_CATEGORY
ATTRIBUTE1
ATTRIBUT2
ATTRIBUT3
ATTRIBUTE4
ATTRIBUTE5
ATTRIBUTE6
ATTRIBUTE7
ATTRIBUTE8
ATTRIBUTE9
ATTRIBUTE10
ATTRIBUTE11
ATTRIBUTE12
ATTRIBUTE13
ATTRIBUTE14
ATTRIBUTE15
ROW_ID
OF RCV_MSH_V
WHERE rcv_msh_v.ship_to_org_id =: 1
and (rcv_msh_v.shipment_header_id in (select rsl.shipment_header_id
of rcv_shipment_lines rsl
where item_id =: 2)) order of shipment_num, expected_receipt_date, shipped_date, shipment_header_id
--------------------------------

I looked on occasion and have add some tips to force the CBO to use vice complete sweep of the index table index scans. I also think that there is a problem with the UNION statement. The following view:

CREATE or REPLACE VIEW FORCE rcv_msh_v (row_id
shipment_header_id,
last_updated_by,
last_update_date,
last_update_login,
created_by,
CREATION_DATE,
program_application_id,
PROGRAM_ID,
program_update_date,
request_id,
ussgl_transaction_code,
government_context,
Comments,
bill_of_lading,
expected_receipt_date,
freight_carrier_code,
from_organization_name,
num_of_containers,
from_organization_id,
$VENDOR_NAME,
vendor_site,
packing_slip,
employe_id,
receipt_num,
receipt_source_code,
shipment_num,
shipped_date,
ship_to_location,
ship_to_location_id,
waybill_airbill_num,
asn_type,
attribute_category,
attribute1,
attribut2,
attribut3,
attribute4,
attribute5,
attribute6,
attribute7,
attribute8,
attribute9,
attribute10,
attribute11,
attribute12,
attribute13,
attribute14,
Attribute15,
vendor_id,
ship_to_org_id,
vendor_site_id
)
AS
SELECT rsh. Row_id ROWID, rsh.shipment_header_id, rsh.last_updated_by,
RSH.last_update_date, rsh.last_update_login, rsh.created_by,
RSH. CREATION_DATE, rsh.program_application_id, rsh.program_id,
RSH.program_update_date, rsh.request_id, rsh.ussgl_transaction_code,
RSH.government_context, rsh.comments, rsh.bill_of_lading,
RSH.expected_receipt_date, rsh.freight_carrier_code,
org.ORGANIZATION_NAME from_organization_name, rsh.num_of_containers,.
RSH.organization_id from_organization_id, NULL, NULL,
RSH.packing_slip, rsh.employee_id, rsh.receipt_num,
RSH.receipt_source_code, rsh.shipment_num, rsh.shipped_date,
HR.location_code ship_to_location, rsh.ship_to_location_id,.
RSH.waybill_airbill_num, rsh.asn_type, rsh.attribute_category,
RSH.attribute1, rsh.attribute2, rsh.attribute3, rsh.attribute4,
RSH.attribute5, rsh.attribute6, rsh.attribute7, rsh.attribute8,
RSH.attribute9, rsh.attribute10, rsh.attribute11, rsh.attribute12,
RSH.attribute13, rsh.attribute14, rsh.attribute15, rsh.vendor_id,
RSH.ship_to_org_id, TO_NUMBER (NULL)
OF rcv_shipment_headers rsh.
hr_locations_all_tl RH,
org_organization_definitions org
WHERE receipt_source_code IN ('INVENTORY', 'ORDER INTERNAL')
AND hr.location_id (+) = rsh.ship_to_location_id
AND human resources. LANGUAGE (+) = USERENV ("LANG")
AND org.organization_id (+) = rsh.organization_id
UNION ALL
SELECT / * + index (top PO_VENDORS_U1) index (rsh RCV_SHIPMENT_HEADERS_N3) * /.
RSH. Row_id ROWID, rsh.shipment_header_id, rsh.last_updated_by,
RSH.last_update_date, rsh.last_update_login, rsh.created_by,
RSH. CREATION_DATE, rsh.program_application_id, rsh.program_id,
RSH.program_update_date, rsh.request_id, rsh.ussgl_transaction_code,
RSH.government_context, rsh.comments, rsh.bill_of_lading,
RSH.expected_receipt_date, rsh.freight_carrier_code, NULL,
RSH.num_of_containers, TO_NUMBER (NULL),
POV. $vendor_name $vendor_name, povs.vendor_site_code vendor_site,
RSH.packing_slip, rsh.employee_id, rsh.receipt_num,
RSH.receipt_source_code, rsh.shipment_num, rsh.shipped_date,
HR.location_code ship_to_location, rsh.ship_to_location_id,.
RSH.waybill_airbill_num, rsh.asn_type, rsh.attribute_category,
RSH.attribute1, rsh.attribute2, rsh.attribute3, rsh.attribute4,
RSH.attribute5, rsh.attribute6, rsh.attribute7, rsh.attribute8,
RSH.attribute9, rsh.attribute10, rsh.attribute11, rsh.attribute12,
RSH.attribute13, rsh.attribute14, rsh.attribute15, pov.vendor_id,
RSH.ship_to_org_id, rsh.vendor_site_id
OF rcv_shipment_headers rsh.
hr_locations_all_tl RH,
po_vendors pov,
POVs po_vendor_sites
WHERE (receipt_source_code = 'SELLER' AND rsh.asn_type IN ('CRASH', "ASBN")
)
AND hr.location_id (+) = rsh.ship_to_location_id
AND human resources. LANGUAGE (+) = USERENV ("LANG")
AND pov.vendor_id = rsh.vendor_id
AND povs.vendor_site_id (+) = rsh.vendor_site_id
- AND (EXISTS)
AND (1 (IN)
SELECT 1
OF rcv_shipment_lines rsl
WHERE rsl.shipment_header_id = rsh.shipment_header_id
AND IN rsl.shipment_line_status_code
("EXPECTED", "PARTIALLY RECEIVED", "FULLY RECEIVED")
AND NOT EXISTS)
SELECT 1
BY rcv_transactions_interface rti
WHERE rti.shipment_line_id =
RSL.shipment_line_id))
);

--------------------------------------------------------------

Any help/advice would be greatly appreciated.

Greg

Published by: user3581064 on August 4, 2010 09:47

Please read these:

When your query takes too long
When your query takes too long...

How to post a SQL tuning request
HOW to: Validate a query of SQL statement tuning - model showing

Tags: Database

Similar Questions

  • Need a tool to investigate SQL performance

    If anyone can share a tool to study the SQL performance?

    Hello

    I don't know if this is a good place but you can opt for Quest Toad, which is one of the most common SQL configuration tool.  However, if you are interesting in SQL performance specifically to your DB, then you can consider SQL tuning packs that come with DB Oracle enterprise edition (careful if you use the standard edition).

    In addition, Oracle has a very nice set of scripts allow you to download... but you must have an account to the Oracle support:

    SQL Tuning-health check Script (SQLHC) (Doc ID 1366133.1)

  • AWR report cannot locate the bad SQLs

    DB version: 11.2.0.2
    Platform: Solaris 10

    In our data base RAC 2 nodes, we have patterns of 20 applications. When an application is faced with performance problems, we try to generate AWR for the period in question. But the stats (like bad SQLs) for this scheme to be buried because there is another application SQLs performing even worse.

    I know that we cannot create AWR report for specific patterns. But I wonder how his stats are collected in a multi-schema RAC environments that will differentiate between applications.

    But the stats (like bad SQLs) for this scheme to be buried because there is another application SQLs performing even worse.

    Since all applications run in a database and query of the other application run bad then they will be the first candidate of tunning since these are taking more resources and impact on other application requests.
    You can also generate report of ASH for module specific or customer with assistance from under the option set in report of ash.

    set target_module_name = ";
    set target_action_name = ";
    set target_client_id = ";

  • SQL performance monitor

    Hello..

    I'm new to sql performance monitor and I need help...

    When I try to create a sql tuning set it asks for a schema to create the tuning series.

    1. what should I use for this?
    2. a particular schema will contain all the sql statements required by the database?
    3.i have multiple schemas in the database... do I do to get all the sql statements for the performance of the database?


    Thank you

    djgeo.

    Hello
    You can select a user database (no application) for the creation of sets of tunng sql

    Salman

  • Satellite Pro S500 - 11 c - bad audio performance

    Hi people,

    I have a Satellite Pro S500 - 11 c who suffers from bad audio performance mentioned in the comments of the S500 - 11 c (yes I * + look + * comments and excuse the pun).

    This makes it very difficult to use this laptop for music, VOIP and Skype without having applications to carry on a heaeset of a certain type.

    Someone at - it to another eperianced this problem and had a solution. No help from Toshiba?

    Best regards

    Andrew

    Sorry, but what kind of problem mean you? Is the sound not loud enough or what?
    I want to say that this laptop has standard stereo speakers and harman/kardon speakers not high-end inside.

    I have the Satellite L300 with same stereo speakers. The sound is OK, but not as good as on other laptops with h/K speakers.

    By the way: what kind of help do you expect? A new driver that makes the speakers more hard maybe?

  • You should know about optimizing SQL performance

    Hi gurus

    I want to know/learn some SQL performance settings, can you please guide me how to I achieve this? Thanks in advance

    Shuumail wrote:

    Can thanks for the reply, you offer me any specific book in your mentioned link?

    The subject itself is not my strong suite, but here are some observations:

    I recently bought the book of Kevin Meade. It is self-published and self published, is not as polished as a lot, but the content seems to be very good.  It establishes a methodical approach with a solid knowledge of the subject.

    Over the years, I've become less enamored of what whether by Burleson.  I was a little surprised to see that one of the books was written by him and Tim Hall.  I do not rely on the website of Mr. Hall for a bunch of stuff 'how to set up'.  On the other hand, if I see a google search show site of Burleson, I usually just pass.

    Whatever it is published by Oracle Press will probably be as solid than anything either, although not totally without error (no book is).  Rich Niemiec is unquestionably one of the top experts on the workings of the oracle, so I expect his book to be very authoritarian.

    I've never been disappointed in a book published by O'Reilly.  They are easy readings and so probably would make a good book "start here."

  • upgrade 9i Sql performance problems, 10 g

    I've heard several times sql performance problem if db upgrade, what is his fix, this problem SQLs appear in ADDM report with Advisor tunning/access sql to run & its suggestions bugs?

    PL see MOS Doc 466181.1 (10 g companion Upgrade) - this topic is covered in this document

    HTH
    Srini

  • No need to advise - compare the date in *.sql with sysdate.

    Hi guys,.

    Need some help here.

    Someone has a script that will compare the date specified with the current sysdate. If previously, he will order that SQL * PLUS to leave immediately.
    The audit will be essentially in a script *.Sql. Whenever we run the script, @c:\script.sql, it will be first of all to compare the dates and decide whether to proceed with the rest of the codes (dml) below the date checker in the same script.sql

    Thank you

    I would like to combine the solutions of bencol and alberto:

    whenever sqlerror exit
    
    DECLARE
       v_date   DATE := TO_DATE('', 'YYYYMMDD');
    BEGIN
       IF v_date >= TRUNC(SYSDATE) -- or perhaps:  v_date>= sysdate
       THEN
         null;
       ELSE
         raise_application_error(-20000,'Date is before SYSDATE!');
       END IF;
    END;
    /
    
    whenever sqlerror continue
    
    -- rest of your script
    ...
    

    (not tested)

    Published by: hm on 08.05.2012 02:51

  • Windows 7 system errors, (CdRom "has a bad block") 7 and 5, (general core hive (file):'-?); affecting performance & need interview help please.

    If I have event viewer saying that "the device, \Device\CdRom0, has a bad block" error Event ID 7, this drive will not format a new CD - R disc, although it used to, I'm running Windows 7, no visible filters in Regedit, (although I deleted the drivers and rebooted), System Restore is no longer an option.  However, DVD - RW works fine otherwise.  What I try next?  And that's probably unrelated, but the general kernel of error event ID 5 is the other thing; "I got a Userid on it and more accurate XML details view on it = 'FinalStatus' > 0x8000002a ExtraString' >------? \C:\Windows\System32\config\COMPONENTS corrupt and recovered - some data could be lost "ExtraStringLength"> 41 Guid ="{A68CA8B7-004F-D7B6-A698-07E2DE0F1F5D}?"

    Hello

    I suggest to run the fix tool from the link provided below and check if this can help:

    http://support.Microsoft.com/mats/cd_dvd_drive_problems/en-us

    Hope this helps,

  • 6210XS SQL Performance Benchmarking

    Our company has recently acquired some new berries for a new ERP system. I am the senior analyst programmer on the project and I'm a beginner-intermediate level on the SAN storage, virtualization and optimization of the performance of SQL. I need to get the speed and at the head of what to expect from this new equipment and best practices to test and manage. Our current ERP is on HP - UX and Informix battery is alien technology in relation to where we are.

    We have a network services division, which was responsible for managing the side home with ESX and EqualLogic 6500 non - ERP. This team is more known in the general management of this equipment, but less time to devote to this new ERP project so I spend to help everyone to get more confidence in the train and educate me about it. Phew. To obtain meat now.

    Setup: dedicated network 10 GB iSCSI with frames enabled. No set MPIO. Dedicated to storage pools for the 6210xs, 6210 (10 K SAS) and 6510 (7200 K). All about the 10 GB.

    I use a tool called MS SQLIO to test the OPS are / s of the 6210XS. I used one of the focus of test by default example of the doc "using SQLIO.

    brief: 6 minutes test, sequential I / O, 2 queries of suspense, of the size of e/s/o requires 256 bytes and a 15 GB test file. The results were:

    H:\SQLIO>SQLIO - kR-s360-fsequential-o2-b256 - LS - Fparam.txt
    SQLIO v1.5.SG
    using meter system for the timings of the latency, 2343750 counts per second
    file settings used: param.txt
    file h:\testfile.dat with 16 (0-15) son using mask 0 x 0 (0)
    16 son of reading for 360 seconds of file h:\testfile.dat
    using 256 KB sequential IOs
    activation of several i/o per thread with 2 exceptional
    the indicated use size: 15000 MB for the file: h:\testfile.dat
    initialization done
    AGGREGATED DATA:
    flow measurements:
    IOs/sec: 133,93
    MBs/s: 33.48
    latency settings:
    Min_Latency (MS): 61
    Avg_Latency (MS): 238
    Max_Latency (MS): 1269

    I made a new test using different settings and had very different results:

    H:\SQLIO>SQLIO - kW - s10 - frandom-o8-b8 - LS - Fparam.txt
    SQLIO v1.5.SG
    using meter system for the timings of the latency, 2343750 counts per second
    file settings used: param.txt
    file h:\testfile.dat with 8 wires (0-7) using mask 0 x 0 (0)
    8 son writing for 10 seconds in the file h:\testfile.dat
    using random 8 KB IOs
    activation of several i/o per thread with 8 exceptional
    the indicated use size: 102400 MB for the file: h:\testfile.dat
    initialization done
    AGGREGATED DATA:
    flow measurements:
    IOs/s: 24122.61
    MBs/s: 188.45
    latency settings:
    Min_Latency (MS): 0
    Avg_Latency (MS): 2
    Max_Latency (MS): 25

    Novice question - this is obviously not a good result, but I need to figure out why my test is configured incorrectly or why the table struggled to perform under these test conditions. Thank you for taking the time to read and respond.

    Usually performance problems are caused by not having is not the SAN (server, switches, table) set up by best practices and in some cases FW drivers and/or obsolete equipment.

    With ESX generally 99% performance problems are solved with:

    Delayed ACK disabled

    People with disabilities large Offload received

    Ensure using Round Robin of VMware (with e / s through changed to 3), or use the EQL MEM (version the most recent is 1.2) Multipathing

    If you use multiple VMDK (or ROW), in the virtual machine, each should have its own virtual SCSI adapter

    Upgrade to the latest build ESX, switch, and server updates

    Take a look at the links listed here first.  See also the Firmware of Array Release notes.

    Best practices for ESX

    en.Community.Dell.com/.../20434601.aspx

    Configuration Guide for EqualLigic

    en.Community.Dell.com/.../2639.EqualLogic-Configuration-Guide.aspx

    Quick Configuration portal (start Grand Place)

    en.Community.Dell.com/.../3615.Rapid-EqualLogic-configuration-Portal-by-SIS.aspx

    Best practices white papers, look for SQL and ESX

    en.Community.Dell.com/.../2632.Storage-Infrastructure-and-solutions-Team-publications.aspx

    Compatibility matrix

    en.Community.Dell.com/.../20438558

    -Joe

  • XMLAGG structure, performance need help for odd nesting in the schema

    Hello

    I have to produce XML to look like:
    <?xml version='1.0'?>
      <enterprise>
        <membership>
          <sourcedid>
            <id>PHYS_101_001_FA2007</id>
          </sourcedid>
        <!-- NOTE: absence of "members" level tag for XMLAGG! -->
        <member>
          <sourcedid>
            <id>D2LU0001</id>
          </sourcedid>
          <role roletype="Sample Role">
            <status>1</status>
          </role>
        </member>
        <member>
          <sourcedid>
            <id>D2LU0002</id>
          </sourcedid>
          <role roletype="Sample Role">
            <status>1</status>
          </role>
        </member>
      </membership>
    </enterprise>
    It would be simple if the scheme allowed for a '< member >' tag under which fit the tags < member >. But it does not this tag, or any other than those listed above.

    I have a query that does not produce this output (with the exception of the roletype attribute), but its execution is horrible; It takes about 40 minutes to return data:
    SELECT
         XMLROOT(
             XMLELEMENT("enterprise",
               XMLAGG(
                 XMLELEMENT("membership",
                   XMLFOREST( XMLELEMENT("id",cx.mapped_course_id) as "sourcedid"
                            ),
                   (SELECT XMLAGG(
                     XMLELEMENT("member",
                       XMLFOREST(XMLELEMENT("id",spriden_id) AS "sourcedid",
                                 XMLELEMENT("status",'1') AS "role"
                                 )
                           )
                          )
                      FROM enrollments_fall_sfrstca efs
                         , spriden sp
                         , gzv_tuid t
                     WHERE sp.spriden_change_ind IS NULL
                       AND sp.spriden_pidm       = t.pidm
                       AND t.tuid                = efs.user_name
                       AND efs.mapped_course_id  = cx.mapped_course_id
                       AND efs.term              = cx.semester
                  )
                    )
                   )
                  )
                , VERSION '1.0', STANDALONE NO VALUE)
      FROM courses_xt cx
    WHERE cx.semester = :term_code
    ;
    Similar queries produce classes and XML users very well without any performance problems, but these are driven out of the view of course or the sight of registrations, but not both.

    Is there another way that I can produce the nesting that I need for the scheme the provider?

    Source views are basically as follows (showing the relevant columns only):
    courses_xt:
    MAPPED_COURSE_ID       SEMEST
    ---------------------- ------
    AVFT209-13307-201210   201210
    AVFT210-13308-201210   201210
    enrollments_fall_sfrstca:
    MAPPED_COURSE_ID       USER_NAME
    ---------------------- ---------
    AVFT209-13307-201210    FULLERC8
    AVFT209-13307-201210    SHUPEK
    AVFT209-13307-201210    NOMAN
    AVFT210-13308-201210    SHUPEK
    AVFT210-13308-201210    PELLONM
    When I make the request without the XML (with subqueries as a column of the outer query), it returns the appropriate fast data (a few minutes).

    I tried various permutations of XMLFOREST, XMLELEMENT, XMLAGG but I get a syntax error, or the data is not going (e.g. repeated "< membership >" for each "< member >", or should I create a "< member >" invalid tag filter later).

    Please advise!

    Thank you
    Anita Lees

    Hi Anita,.

    Have you tried with a GROUP BY and any subquery?

    Here is an example of the use of schema SCOTT.
    I used the same names to tags and structure so that you can see the analogy:

    SELECT XMLElement("enterprise",
             XMLAgg(
               XMLElement("membership",
                 XMLElement("sourceid", xmlelement("id", d.deptno))
               , XMLAgg(
                   XMLElement("member",
                     XMLElement("sourceid",
                       XMLElement("id", e.empno)
                     )
                   , XMLElement("role",
                       XMLAttributes(e.job as "roletype")
                     , XMLElement("status", '1')
                     )
                   )
                 )
               )
             )
           )
    FROM scott.dept d
         LEFT OUTER JOIN scott.emp e ON e.deptno = d.deptno
    WHERE d.deptno IN (10,20)
    GROUP BY d.deptno
    ;
    

    What gives:

    
      
        
          10
        
        
          
            7782
          
          
            1
          
        
        
          
            7934
          
          
            1
          
        
        
          
            7839
          
          
            1
          
        
      
      
        
          20
        
        
          
            7369
          
          
            1
          
        
        
          
            7902
          
          
            1
          
        
        
          
            7566
          
          
            1
          
        
      
    
    
  • SQL Performance question

    Hello

    The following query performs badly when the predicate

    AND (v_actionFlag IS NULL or ACTION_CODE = v_actionFlag)

    is present. In all executions of the query v_actionFlag will be NULL. In addition, because of the plan when the predicate is included, the returned results are incorrect. We seek to treat rows with the lowest priority. With the included predicate query performs the join, gets 20 lines, sorts, and puts back them rather than getting 20 lines with the lowest priority through the index of QUEUE_TAB0 and return of these.

    The questions I have are-

    -Why the predicate affects the query in this way
    -What is the difference between the HASH JOIN ANTI and HASH JOIN RIGHT ANTI


    We were able to remove this predicate as the functionality it supports has not yet been implemented.



    Background

    Version of DB - 10.2.0.4
    optimizer_features_enable - 10.2.0.4
    optimizer_mode - ALL_ROWS
    Table
    
    - table has approximately 475,000 rows and the statistics are up to date
    
    
    sql> desc queue_tab
     Name                                      Null?    Type
     ----------------------------------------- -------- ----------------------------
     ENTITY_KEY                                NOT NULL NUMBER(12)
     ENTITY_TYPE                               NOT NULL CHAR(1)
     ACTION_CODE                               NOT NULL CHAR(1)
     REPORT_NO                                 NOT NULL NUMBER(12)
     PRIORITY                                  NOT NULL NUMBER(4)
    
    
    
    Indexes
    
    Primary Key (QUEUE_TAB_PK)
    
     ENTITY_KEY                                 
     ENTITY_TYPE                                
     ACTION_CODE                                
     REPORT_NO 
    
    
    Non Unique Index (QUEUE_TAB0)
    
     PRIORITY  
     ENTITY_KEY   
     ENTITY_TYPE  
     ACTION_CODE 
    
    
    
    Cursor
    
    
            SELECT /*+ INDEX_ASC (main QUEUE_TAB0) */
                   REPORT_NO
                 , ENTITY_TYPE
                 , ENTITY_KEY
                 , ACTION_CODE
                 , PRIORITY
              FROM QUEUE_TABV01 main
             WHERE PRIORITY > 1
               AND (v_actionFlag IS NULL OR ACTION_CODE = v_actionFlag )
               AND NOT EXISTS
                   ( SELECT /*+ INDEX_ASC (other QUEUE_TAB_pk) */ 1
                       FROM QUEUE_TABV01 other
                      WHERE main.ENTITY_TYPE = other.ENTITY_TYPE
                        AND main.ENTITY_KEY = other.ENTITY_KEY
                        AND main._ACTION_CODE IN ( constant1, constant2 )
                        AND other.ACTION_CODE IN ( constant3, constant4 ) )
               AND NOT EXISTS
                   ( SELECT 1 FROM QUEUE_TABV01 multi
                      WHERE main.ENTITY_TYPE = multi.ENTITY_TYPE
                        AND main.ENTITY_KEY = multi.ENTITY_KEY
                        AND multi.PRIORITY = 1 )
               AND ROWNUM < rowCount + 1
             ORDER BY PRIORITY, ENTITY_KEY, ENTITY_TYPE,
                      ACTION_CODE;
    
    
                                     
    Plan when predicate "AND (v_actionFlag IS NULL OR ACTION_CODE = v_actionFlag )" is present
    
    
    call     count       cpu    elapsed       disk      query    current        rows
    ------- ------  -------- ---------- ---------- ---------- ----------  ----------
    Parse        1      0.00       0.00          0          0          0           0
    Execute      1      0.00       0.00          0          0          0           0
    Fetch       21      5.53       5.40          2     780463          0          20
    ------- ------  -------- ---------- ---------- ---------- ----------  ----------
    total       23      5.53       5.40          2     780463          0          20
    
    Misses in library cache during parse: 0
    Optimizer mode: ALL_ROWS
    Parsing user id: 60     (recursive depth: 1)
    
    Rows     Row Source Operation
    -------  ---------------------------------------------------
         20  SORT ORDER BY (cr=780463 pr=2 pw=0 time=5400939 us)
         20   COUNT STOPKEY (cr=780463 pr=2 pw=0 time=5400872 us)
         20    HASH JOIN ANTI (cr=780463 pr=2 pw=0 time=5400823 us)
     459033     TABLE ACCESS BY INDEX ROWID QUEUE_TAB (cr=780460 pr=2 pw=0 time=4640394 us)
     459033      INDEX RANGE SCAN QUEUE_TAB0 (cr=608323 pr=1 pw=0 time=3263977 us)(object id 68038)
      10529       FILTER  (cr=599795 pr=1 pw=0 time=2573230 us)
      10529        INDEX RANGE SCAN QUEUE_TAB_PK (cr=599795 pr=1 pw=0 time=2187209 us)(object id 68037)
          0     INDEX RANGE SCAN QUEUE_TAB0 (cr=3 pr=0 pw=0 time=34 us)(object id 68038)
    
    
    
    
    Plan when predicate "AND (v_actionFlag IS NULL OR ACTION_CODE = v_actionFlag )" is removed
    
    
    call     count       cpu    elapsed       disk      query    current        rows
    ------- ------  -------- ---------- ---------- ---------- ----------  ----------
    Parse        1      0.00       0.00          0          0          0           0
    Execute      1      0.02       0.00          0          0          0           0
    Fetch       21      0.05       0.05          0       6035          0          20
    ------- ------  -------- ---------- ---------- ---------- ----------  ----------
    total       23      0.07       0.06          0       6035          0          20
    
    Misses in library cache during parse: 1
    Misses in library cache during execute: 1
    Optimizer mode: ALL_ROWS
    Parsing user id: 60     (recursive depth: 1)
    
    Rows     Row Source Operation
    -------  ---------------------------------------------------
         20  SORT ORDER BY (cr=6035 pr=0 pw=0 time=54043 us)
         20   COUNT STOPKEY (cr=6035 pr=0 pw=0 time=962 us)
         20    HASH JOIN RIGHT ANTI (cr=6035 pr=0 pw=0 time=920 us)
          0     INDEX RANGE SCAN QUEUE_TAB0 (cr=3 pr=0 pw=0 time=53 us)(object id 68038)
         20     TABLE ACCESS BY INDEX ROWID QUEUE_TAB (cr=6032 pr=0 pw=0 time=701 us)
         20      INDEX RANGE SCAN QUEUE_TAB0 (cr=6001 pr=0 pw=0 time=533 us)(object id 68038)
         40       FILTER  (cr=199 pr=0 pw=0 time=2048 us)
         40        INDEX RANGE SCAN QUEUE_TAB_PK (cr=199 pr=0 pw=0 time=1975 us)(object id 68037)

    user599445 wrote:
    Hello Justin and Camille,

    Thank you for taking the time to look at it. I changed the query to correctly practice the ROWNUM. I run and traced the query with the predicate IS NULL and without, with each track below. As you both have suggested that the predicate appears to have no impact on the plan does. All feedback is appeciated.

    Mark,

    the obvious problem with the new plan is that no record is filtered by the first NOT EXISTS clause (using anti-join operation), and then for each line an index seek is performed that filters the records only about 14 000. It is the search for index that takes most of the time, gets consistent since he performs about 2 e/s logic by research, in total nearly 1 million.

    The last 456 000 rows are then sorted (top n) and the top 20 are returned.

    A possible problem could be that the optimizer does not switch mode optimization first_rows_N due to the variable binding used in the filter ROWNUM.

    You can try to execute the statement using a literal (ROWNUM< 21)="" instead="" of="" the="" bind="" variable="" to="" see="" if="" it="" changes="">

    I think in this case, it could be much more effective for the QUEUE_TAB0 of the market index in the order requested and perform the two NOT EXISTS clause as activities of recursive filters provided as your ROWNUM predicate is generally rather low.

    Be aware however that is you do not use a "binary" NLS_SORT index parameter can not be used for an operation of NOSORT ORDER BY STOPKEY of CHAR values, so please check your settings NLS (NLS_SESSION_PARAMETERS. PARAMETER = "NLS_SORT") in which case the optimizer will not use the index for sorting. Note that the NLS parameters are customer specific and can theoretically be different for each session / client.

    You can test this by using a query simple top N: SELECT * FROM (SELECT * ACTION_CODE, ENTITY_TYPE, ENTITY_KEY, QUEUE_TAB ORDER OF PRIORITY) WHERE ROWNUM<>

    If it does not use the QUEUE_TAB0 index to stop the sort operation, you might have a problem with the NLS parameters.

    In order to prevent the transformation of the GUESSED you can also try adding a hint NO_UNNEST two subqueries ("SELECT / * + NO_UNNEST * /...") ("in the respective subquery) and you can also try to switch mode FIRST_ROWS (n) using for example the FIRST_ROWS indicator (20) in the body of the request (but which must be done by the ROWNUM predicate).

    Kind regards
    Randolf

    Oracle related blog stuff:
    http://Oracle-Randolf.blogspot.com/

    SQLTools ++ for Oracle (Open source Oracle GUI for Windows):
    http://www.sqltools-plusplus.org:7676 /.
    http://sourceforge.NET/projects/SQLT-pp/

  • Satellite R830 - 10 c: needing an adviser

    Hi guys,.

    Just wondering if there was someone out there with a Satellite R830 - 10 c who could advise me on how hot attributed to it.

    I'm looking to upgrade a netbook to one (cheapish) ultraportable and this looks like a really good report quality / price and well reviewed. However, I saw a few comments on the R830 - 11 c and -143 which seem to indicate that they are very hot on the bottom.

    I realize the 10 c is less powerful, so should work more fresh, but I need to be able to use it on my knees, leave it on sofa arms (not duvets or something stupid) etc. without any problem or I'm better to go for something bigger and cooler.

    Your advice would be much appreciated
    Tintalla

    The left side can get a little warm, but I don't think it's a shame. If you're just in the internet or light something else, then it remains relatively cool.

    If you are worried about the heat, you can be better off getting a slightly larger model with a larger chassis as the Tecra R840.

  • Router bad for my needs

    I think I left a pretty advertising convince me to buy a product that is not suitable for my needs. I hope someone here can shed some light on this for me as I'm new to the home wireless network.

    I have a box of Ubuntu (8.04) wired to a modem cable; I set it up as a dual-boot machine so that I can get to Windows XP Professional if necessary.
    I have also a laptop Dell under Ubuntu I use it especially when I'm on the road for work on the email, or for forcing me to the remote access connection is my work computer (Windows Remote Desktop; I run IE6 in a shell of wine) or my computer at home (whether through VNC viewer or "UltraVNC" under XP).
    I also, in my "spare" time, do some computer repairs coffee table for friends and co-workers.

    Here's what I would do:
    I would like to be able to have a switch or a router that would allow me to have the ability to keep my main box Ubuntu/XP connected directly on an internet connection "always on."
    I would also like to be able to have the laptop hooked up to a connection "always on", but I don't know that it's a show-stopper if I have to jump some hoops when I want to connect it.
    I would also like to have a port available to connect to the internet with any random computer I find myself working on.
    Finally, I would like to be able to use the card on the lappy's wireless to connect to a network in my house without the need for a dedicated thread.

    That being said... I did a few quick searches (* too * fast it seems!), and it looked as if the WRT54GL would do everything that I need.
    So... being new in the world of wireless home network, I made sure to carefully follow each step on the CD (XP)... and everything went well for a while...

    But, every few hours, the internet connection will just go away. By that, I mean... the status of internet light is green, so I guess that the router can see the internet, and the lights on the two connected computers (portable and desktop) are green, so I guess that means that the router can also see computers. But neither machine can connect to the internet at all. ifconfig returns 192.168.101, so that the router is visible to the computer, it seems just that the router is not allowing to each machine, on one of the 4 ports, see the internet.
    Now, this occurs after the connection has worked very well for hours.
    The fix for this seems to be one of two things... Either I cycle the power on the router, then I need to refresh the list of devices on the computers (or select "repair network" on the XP machine).
    The alternative is to go to the configuration of the web browser and select "Release DHCP" and then "Renewing DHCP", which is fine, I wish only that it has been documented somewhere to do this it would have saved me several hours of work to understand.
    A lady 'live support' had me to Flash the firmware in response to my question about this, the following was told to "watch carefully", whatever that means. She couldn't explain it further.
    But after that, the connection works again for several hours in a row, then it will disappear all simply once again.
    Now - in addition to this, here is the part that makes me think that I have chosen the right product... I am is no longer capable of connection of remote access to my computer at home using the IP, as reported by ifconfig (which has always worked in the past) or subdomain name, I've implemented with DynDNS (which also worked) of any machine to everything, including the XP box that I use in my office at work (who has always worked in the past.)
    After spending countless hours just trying to get this router to perform because I thought it would, I have yet to try to venture into the side of things wireless. If a wired switch - this befuddling, so I can only imagine what a nightmare it will be to get the wireless side to work.

    I guess the bottom line is this: I unplugged the router and plugged the main engine directly into the cable modem, and everything works as it should.
    Can anyone recommend a good, reliable and always on router that will allow me to connect up to three computers simultaneously without having to go through hoops at a port?
    And to be honest, I'm not really interested in the wireless; the restaurant down the street allows me to connect very easily if I put my lappy near the living room window

    Thanks in advance.

    (edit - the formatting of this post was horrible... I added HTML line breaks and it's much better now!)

    Message edited by mwright on 30/09/2008 06:03

    Unable to find good answers from live support or my repeated e-mails asking when the mysterious 'fixed' firmware, I turned to the internet for all the suggestions...

    I downloaded and installed the "DD - WRT" firmware, and for three days straight, I did not have a problem with my WRT54GL.  It allows me to connect, * stays * connected, I cannot remote connection without any problems, and the wireless was working immediately.

    I think that linksys should take note... I don't know if it's the ultimate solution, but it seems well have solved the problems that linksys has not been able to fix for me at all.

  • Inpiron 15R 5537 - bad game performance or prolonged inability to sleep/wake?

    This post is a complaint and a call for a solution that is a real tool for troubleshooting.

    The problem is: after I've updated my notebook to Windows 8.1, I noticed on the screen would not back off from his sleep. I instantly would google for answers and I found out, it could get fixed if I installed the latest drivers HD from Intel and AMD. All together and made, the problem was finally fixed, and everything seems to work perfectly... Until I installed Left 4 Dead 2 and tried to test: the video performance was incredibly ADMIN NOTE: replace character removed according to the TOU >. I was like ' Jesus, this is only of L4D2 and this graphics card can't handle even the menu scren! So I google'd, because a HD 8850 M, which does not have a game as old as that is not normal. Has been my solution: install generic drivers from AMD. And the problem was over. Not only that, I was able to play the same field 4. But then I've locked the computer and has failed to wake it back up... again...

    Long story short: I'm mad on this subject and I really wan't to know: why the ADMIN NOTE: replace character removed according to the TOU > you guys put HD Graphics of Intel and AMD HD Board altogether? If I have a NOTE from the ADMIN: replace character removed by TOU > 8850 M why the hell I'm going to need a NOTE from the ADMIN: replace character removed according to the TOU > Intel HD Graphics? If you guys had this brilliant idea, why aren't you able to develop a decent driver, one that allows the 8850M high performance, it can handle and the HD from Intel to manage anything, should it manage? and finally: is there is a solution to both problems, which is?


    Thanks in advance for any help that is actually useful.

    A dissatisfied customer.

    Guys got the solution

    I did it on my Inspiron 15R 5537 with AMD 8850 M over Windows 8.1

    1. update the version of the Bios A08 link: http://www.dell.com/support/home/in/en/indhs1/Drivers/DriversDetails?driverId=6D4JN&fileId=3381798009&osCode=WB64A&productCode=inspiron-15r-5537&languageCode=EN&categoryId=BI

    2 uninstall display drivers using Uninstaller to display in safe MODE driver

    3. install the link worm 10.18.10.3308 Dell Intel graphic driver: http://www.dell.com/support/home/in/en/indhs1/Drivers/DriversDetails?driverId=Y3FHH&fileId=3321814127&osCode=WB64A&productCode=inspiron-15r-5537&languageCode=EN&categoryId=VI

    and restart

    4. install the latest AMD Catalyst Mobility 14.4 for AMD support site link: http://support.amd.com/en-us/download/mobile?os=Windows%208.1%20-%2064#amd-catalyst-packages

    and restart

    5. open CMD as administrator, and then type "powercfg - restoredefaultschemes.

    6. download and open AMDEnduroFix_DX9 and click on apply the hotfix and restart the link: https://docs.google.com/file/d/0BwMfCsXwjEEeeEZKWFVpMzM2b28/edit

    7.enjoy.

    without sleep/hibernation problems and performance of game are very good.

    The name in Device Manager is AMD R9 M265X but ignore it. Do not worry

Maybe you are looking for

  • Base material Labivew

    I am able to download documents about version 8.5, but where can I get the last bases of material Labivew (last version) LabVIEW Basics I LabVIEW Basics II Data acquisition courses and other newer materials.

  • Need driver of device and/or software for my printer Epson Stylus NX420

    I have misplaced my original software for my Epson Stylus NX420 printer and have so far not been able to locate online. Very frustrating, in fact, as I just replaced ink cart., etc.. I had printer for a while, because it was installed on an older dev

  • Why used my sim city 4 cd install on windows 7

    Tried to install Sim City 4 on Windows 7 cd rom doesn't even begin. I called HP, they told me that it is not compatible. Is there any solution for this and where.

  • where's my email?

    Recently, I reported to you that my email has been HACKED, I followed all the necessary instructions, as you suggested, I removed the third (pirate) to yahoo my email account. I changed my password, I still haven't received email what is wrong? I con

  • Adding a WIFI card to a desktop HP Pavilion

    Does anyone has installed a WIFI card in a HP Pavilion a6242n desktop computer?  If so, do you have recommendations for card manufacturers and models? Thank you!