Faster response time of queries

I have a query which joins a few tables with seveeral thousand rows each. This query normaly returns tens of thousands and the response time is almost 10 minutes and it's not acceptable for web application.
To speed it up I just want Oracle to return the first let's say 1000 rows.
Changing the max rows returned parameter(APEX) to 1000 doesn't help at all. It seems like query executes in full and then only the first 1000 rows of the resultset are sent.
So my question is: is there way to instruct Oracle to stop execution of the query once first n rows are retrieved?
I tried the SELECT /* FIRST_ROWS(1000) */ .... but this doesn't help. and I wonder how could it when it seems that TOAD determines this as a comment and doesn't change the optimizer mode - still ALL_ROWS.
What am I doing wrong here, this is the first time I am trying to use FIRST_ROWS hint , - is there another - better way to speed up my query?

Hi Bob, thanks for the response. rownum < n was the first thing I tried. One would think that if a query takes 5 minutes to execute and returns 50 000 rows then after adding rownum < 5000 it shuldn't take more than a minute - well it takes pretty much the same time as w/out rownum < n. It seems like rownum is determined for the whole resultset and then the where codition is applied.
The tables actually have much more than a few thousand rows. one is with close to 250 000 and couple other tables with over a million and I don't see much that I can optimize. I think being able to only return certain first n rows fast for web applications must be fairly common situation when dealing with large tables/views.

Similar Messages

  • How to improve response time of queries?

    Although it looks that that this question relates to Reports but actually the problem is related to SQL.
    I have a Catalogue type report which retrieves data and prints. That is not much calculations involved.
    It uses six tables.
    The data model is such that I have a separate query for each table and then all
    these tables are liked thru link tool.
    Each table contains 3000 to 9000 rows but one table contains 35000 rows.
    The problem is that the report is taking too much time - about 3-1/2 hours while
    expectation is that it should take 20 to 40 minutes max.
    What can I do to reduce the time it takes to produce report.
    I mean should I modify data model to make a single query with equi-join?
    A)Specially I want to know what is traffic between client and server when
    1) we have multiple quieries and LINK tool is used
    2) Single query and equi-join is used
    B)Which activity is taking most of time ?
    1) Retrieving data from server to client
    2) Sorting according to groups (at client) and formating data and saving in file
    Pl. guide.
    Every body is requested to contribute as per his/her experience and knowledge.
    M Tariq

    Generally speaking, your server is faster than your PC (if it is not, then you have bigger problems than a slow query), let the server do as much of the work as possible, particularly things like sorting, and grouping. Any calculations that can be pushed off onto the server (e.g. aggregate functions, cola + colb etc.) should be.
    A single query will always be faster than multiple queries. Let the server do the linking.
    The more rows you return from the server to your PC, the more bytes the network and your PC have to deal with. Network traffic is "expensive", so get the result set as small as possible on the server before sending it back over the network. PC's generally have little RAM and slow disks compared to servers. Large datasets cause swapping on the PC, this is really expensive.
    Unless you are running on a terribly underpowered server, I think even 30 - 40 minutes would be slow for the situation you describe.

  • Response times to queries

    I have a number of unresolved queries with BT that have been ongoing for quite some time. I have recently received a Final bill as BT seem to no longer want me as a customer and my emails are being ignored.
    I have advised them that i wish to escalate my query as i am not satisfied with the lack of a response however there has been no reaction.
    Can anyone confirm whether i am wasting my time and should just pay up and shut up?

    Hi SuffolChap,
    I would like to take a look at the details of your complaint. Please could you send me in your details using the link found in the "About me" section of my profile?
    Thanks
    Paddy
    BTCare Community Mod
    If we have asked you to email us with your details, please make sure you are logged in to the forum, otherwise you will not be able to see our ‘Contact Us’ link within our profiles.
    We are sorry but we are unable to deal with service/account queries via the private message(PM) function so please don't PM your account info, we need to deal with this via our email account :-)

  • Explain plan - lower cost but higher response time in 11g compared to 10g

    Hello,
    I have a strange scenario where 'm migrating a db from standalone Sun FS running 10g RDBMS to a 2-Node Sun/ASM 11g RAC env. The issue is with response time of queries -
    In 11g Env:
    SQL> select last_analyzed, num_rows from dba_tables where owner='MARKETHEALTH' and table_name='NCP_DETAIL_TAB';
    LAST_ANALYZED NUM_ROWS
    11-08-2012 18:21:12 3413956
    Elapsed: 00:00:00.30
    In 10g Env:
    SQL> select last_analyzed, num_rows from dba_tables where owner='MARKETHEALTH' and table_name='NCP_DETAIL_TAB';
    LAST_ANAL NUM_ROWS
    07-NOV-12 3502160
    Elapsed: 00:00:00.04If you look @ the response times, even a simple query on the dba_tables takes ~8 times. Any ideas what might be causing this? I have compared the XPlans and they are exactly the same, moreover, the cost is less in the 11g env compared to the 10g env, but still the response time is higher.
    BTW - 'm running the queries directly on the server, so no network latency in play here.
    Thanks in advance
    aBBy.

    *11g Env:*
    PLAN_TABLE_OUTPUT
    Plan hash value: 4147636274
    | Id | Operation | Name | Rows | Bytes | Cost (%CPU)| Time |
    | 0 | SELECT STATEMENT | | 1104 | 376K| 394 (1)| 00:00:05 |
    | 1 | SORT ORDER BY | | 1104 | 376K| 394 (1)| 00:00:05 |
    | 2 | TABLE ACCESS BY INDEX ROWID| NCP_DETAIL_TAB | 1104 | 376K| 393 (1)| 00:00:05 |
    |* 3 | INDEX RANGE SCAN | IDX_NCP_DET_TAB_US | 1136 | | 15 (0)| 00:00:01 |
    PLAN_TABLE_OUTPUT
    Predicate Information (identified by operation id):
    3 - access("UNIT_ID"='ten03.burien.wa.seattle.comcast.net')
    15 rows selected.
    *10g Env:*
    SQL> select * from table(dbms_xplan.display);
    PLAN_TABLE_OUTPUT
    Plan hash value: 4147636274
    | Id | Operation | Name | Rows | Bytes | Cost (%CPU)| Time |
    | 0 | SELECT STATEMENT | | 1137 | 373K| 389 (1)| 00:00:05 |
    | 1 | SORT ORDER BY | | 1137 | 373K| 389 (1)| 00:00:05 |
    | 2 | TABLE ACCESS BY INDEX ROWID| NCP_DETAIL_TAB | 1137 | 373K| 388 (1)| 00:00:05 |
    |* 3 | INDEX RANGE SCAN | IDX_NCP_DET_TAB_US | 1137 | | 15 (0)| 00:00:01 |
    Predicate Information (identified by operation id):
    3 - access("UNIT_ID"='ten03.burien.wa.seattle.comcast.net')
    15 rows selected.
    The query used is:
    explain plan for
    select
    NCP_DETAIL_ID ,
    NCP_ID ,
    STATUS_ID ,
    FIBER_NODE ,
    NODE_DESC ,
    GL ,
    FTA_ID ,
    OLD_BUS_ID ,
    VIRTUAL_NODE_IND ,
    SERVICE_DELIVERY_TYPE ,
    HHP_AUDIT_QTY ,
    COMMUNITY_SERVED ,
    CMTS_CARD_ID ,
    OPTICAL_TRANSMITTER ,
    OPTICAL_RECEIVER ,
    LASER_GROUP_ID ,
    UNIT_ID ,
    DS_SLOT ,
    DOWNSTREAM_PORT_ID ,
    DS_PORT_OR_MOD_RF_CHAN ,
    DOWNSTREAM_FREQ ,
    DOWNSTREAM_MODULATION ,
    UPSTREAM_PORT_ID ,
    UPSTREAM_PORT ,
    UPSTREAM_FREQ ,
    UPSTREAM_MODULATION ,
    UPSTREAM_WIDTH ,
    UPSTREAM_LOGICAL_PORT ,
    UPSTREAM_PHYSICAL_PORT ,
    NCP_DETAIL_COMMENTS ,
    ROW_CHANGE_IND ,
    STATUS_DATE ,
    STATUS_USER ,
    MODEM_COUNT ,
    NODE_ID ,
    NODE_FIELD_ID ,
    CREATE_USER ,
    CREATE_DT ,
    LAST_CHANGE_USER ,
    LAST_CHANGE_DT ,
    UNIT_ID_IP ,
    US_SLOT ,
    MOD_RF_CHAN_ID ,
    DOWNSTREAM_LOGICAL_PORT ,
    STATE
    from markethealth.NCP_DETAIL_TAB
    WHERE UNIT_ID = :B1
    ORDER BY UNIT_ID, DS_SLOT, DS_PORT_OR_MOD_RF_CHAN, FIBER_NODE
    This is the query used for Query 1.
    Stats differences are:
    1. Rownum differes by apprx - 90K more rows in 10g env
    2. RAC env has 4 additional columns (excluded in the select statement for analysis purposes).
    3. Gather Stats was performed with estimate_percent = 20 in 10g and estimate_percent = 50 in 11g.

  • Discoverer Performance/ Response Time

    Hi everyone,
    I have a few questions regarding the response time for discoverer.
    I have Table A with 120 columns. I need to generate a report based on 12 columns from this table A.
    The questions are whether the factors bellow contribute to the response time of discoverer.
    1. The number of items included in the business area folder (i.e. whether to include 120 cols or just 12 cols)
    2. The actual size of the physical table (120 cols) although I only selected 12 cols. If the actual size of the physical table is only 12 cols, would it improve the performance?
    3. Will more parameters increase the processing time?
    4. Does Joins increase the processing time?
    5. Will using Custom Folder and writing an sql statement to select the 12 columns increase the performance?
    Really appreciate anyone's help on this.
    Cheers,
    Angeline

    Hi,
    NP and Rod, thanks a lot for your replies!
    Actually I was experiencing a different thing that contradicts your replies.
    1. When I reduced the no of items included in my Biz Area from 120 to 12 the response time improve significantly from around 5 minutes to 2-3 minutes.
    2. When I tried to create a dummy table with just 12 cols needed for the report, I could get a very fast response time, i.e. 1 second to generate the report. But of course the dummy table contains much less data (only around 500 K records). Btw, is Discoverer able to handle large database? What is the biggest record size can it handle?
    3. When I add more parameters it seems to add more processing time to the discoverer.
    4. Thanks for the clarification on this one.
    5. And the funny thing is, when I use custom folder to just select the 12 columns, the performance also significantly improves with estimated query time reduced from 2 minutes plus to just 1 mins 30 secs. But still the performance time is inconsistent. Sometimes it only takes around 1 mins 40 secs, but sometimes it can run up to 3 mintues for the same data.
    Now I am creating my report using the custom folder cause it has the best response time so far for me. But based on your replies it's not really encouraged to use the custom folder?
    I need to improve the response time for the Discoverer Viewer as the response time is very slow and users don't really like it.
    Would appreciate anyone's help in solving this issue :) Thanks..
    Cheers,
    Angeline

  • 12ms response time... is this rather slow for a high cost display?

    I was waiting to buy the new 27" display but now that it has been arrived at a cost of £899 in the UK I am looking at cheaper alternatives, accepting that cheaper will probably mean lower spec. I am surprised to find that many much lower priced displays from manufacturers such as LG, HP, and Samsung appear to have faster response times, for instance 2ms or 5ms, whereas the Apple display's response time is listed as being 12ms. I think I am correct in thinking that a lower response time means that fast action video looks better on screen, but this doesn't seem to make sense that such an expensive and high quality display as Apple's would be slower, so am I misunderstanding something here?
    What are the most important figures to take account of when looking at the spec of a good display?

    You can look at other manufactures. Their price is usually lower. I have a HP 24" with a IPS LCD screen. Apple doesn't have an exclusive on IPS screens.
    http://www.anandtech.com/show/3946/apple-27inch-led-cinema-display-review
    I see you are in the UK.
    This site is better.
    http://www.tftcentral.co.uk/reviews.htm

  • FASTER RESPONSE FROM keyboard/mouse actions?

    1.42 GHz PPC G4, 1GB DDR SD Ram (4200 rph HD)
    How can I DECREASE computer RESPONSE action/time to day to day activities?
    It is not clear what 'slows down' software/computer responses and causes the spinning balls in relatively simple actions.
    My usage is not 'heavy' nor 'complex'; Typically Mail, Safari, FoxFire, Word 2007, TextEditPlus,
    QuickTime (music on occasion). Occasionally Adobe Reader and Photoshop Elements. Safari often more spinning balls than others.
    By turning OFF USB an external HD with switching Power Supply that helps avoid delays. But what
    else can be done?
    I choose to stay with Tiger 10.4.11 - and do NOT chose to go to a later version of the OS.
    Is there a "faster response" time for later versions of the Mini?
    Given that my first Mac was a 400k floppy machine with MacWrite and MacDraw - in relative terms we I do now is like a supersonic jet... but mine needs a booster -
    ideas??

    Your computer's list of items in-use, per Activity Monitor, tell you
    what is running and while these are Active, give an idea of how
    much of the computer's configuration (hard/soft-ware) resources
    are being used. Also, the Activity Monitor can tell you the load
    of Virtual Memory and actual Chip RAM demands of Apps.
    The interface of USB mouse and keyboard can act slowed-down
    when the computer resources are running loaded. Even with up
    to 75% hard disk drive free-space (unused, except for system
    use as Virtual Memory and application temp or swap space) my
    computer with an 8GB HDD can also, at times, have a slow key-
    board and mouse.
    If you have more than one browser window open, or run Office
    and some other apps at the same time, the overall load on the
    Mini G4 (with the 1024MB max RAM installed) can be critical.
    The virtual memory write/read cycles to the hard disk drive
    increase, and this will also add to a lag when there is a rush
    of demand on diminishing resources; plus, a tired old HDD.
    Do you occasionally log-out of the main user account and log
    back in? This can sometimes help free-up RAM and other use
    of system resources, without having to restart the Mac.
    How often do you restart the computer, & do you leave it to sleep
    when not in use, or do you power it off? Just curious.
    As the computer gets older and the hard disk drive more worn,
    it may be running warmer and slower; less efficiently and tired,
    this lag may be more apparent and point to a need to replace
    the internal hard disk drive with a new, larger & better spec unit.
    In some instances, there had been a controversy over which was
    faster to the computer's processor and RAM (system bus) - be it
    a 400 Mbit FW400 external hard disk drive, or a hard disk drive
    on the computer's own bus. Some tests, machine series dependant,
    showed a variable; with some FW400 enclosures running slower
    than the internal computer's hard disk drive.
    I've found both slower and faster (depending on the computer)
    using an external HDD in FireWire400 enclosure, vs the native
    drive; with even a 7200 RPM 250GB HDD running thoroughput
    slower than an internal 5400 RPM 80GB drive; but not always.
    Do you use a powered USB hub with the peripheral items your
    computer is attached to, when running the Mini? For mine, the
    better setup was to use powered USB hubs, with the keyboard
    plugged directly into the Mac (for startup keyboard combo access)
    and the mouse plugged into a port on the powered USB hub.
    To note, if there is an issue with this set-up, to troubleshoot the
    powered USB hub and have a spare keyboard & mouse available.
    Usually, an over-whelmed USB port in a computer will give you a
    warning message implying an under-powered state exists, & near
    the total possible output of voltage to the USB port is approached.
    The USB bus can only support a limited ceiling; there also is a limit
    on FW port loads, and devices exceeding that amount will affect all
    items on their respective bus. (Example why self-powered is best.)
    When you went to the AppleJack download page and clicked on
    the link to get the download to start, does your browser show you
    a Downloads list and ask you where/how you want the item saved?
    I have mine set so I can see any/all items, choose to install them;
    & have the .dmg or other image file on the desktop where I can
    see it. (In 10.5.8, the default is in a Dock location for Downloads.)
    How the browser is set to handle downloads can affect results.
    If your computer has been acting oddly, there may be some
    kind of file corruption or data corruption causing issues in it.
    This link, in Firefox, goes to the download item for AppleJack
    directly, in my browser, the default is set and asks me what
    I want to do about it. The main option is to accept it and then
    it will download to the desktop (Tiger 10.4.11) as a .dmg. It
    will not open, and does not display some kind of picture:
    http://sourceforge.net/projects/applejack/files/AppleJack/AppleJack-1.6/AppleJac k-1.6.dmg/download
    You should make a good backup, a bootable clone of your Mini's
    entire hard disk drive contents, test it well, and then consider a
    course of maintenance and repair of the internal hard drive; or get
    a new replacement hard disk drive and upgrade the Mini with it.
    Only 5 interruptions here, in the course of this reply to the question.
    (Could be worse; some days they can be hours long; or weeks.
    There is a story, non-computer related to the reader, going on.)
    {Spindown Fix software has been tested in Mac OS X 10.2.3 only.
    The older software suggested, may help if the external is going to
    sleep if used as a boot startup volume; since once a external boot
    FW goes to sleep, the computer may not see it when it awakens.}
    The Mini is sort of like a portable computer, in that the hard drive
    gets a thorough work-out and it has limited upgrade capabilities.
    So, for a hard disk drive to last 3 to 5 years, is lucky run. At least
    the unit isn't being hauled around while asleep, as a 'Book may;
    and isn't as likely to be dropped from the lap while it's running...!
    +{Yes, it's a long post. Sorta like a Totem.}+
    Good luck & happy computing!
    edited 2x

  • 16 ms response time - is it noticable?

    I really want to plunk down the cash for a 23"...but that response time is just killing me...there are many displays out now that have it down to 5 ms or less...
    I am currently on a 20" iMac...will I notice a difference?

    Hi-
    It all depends on what your uses are. The response time of a monitor will only really be noticeable in watching DVD movies, TV (action, sports), or if you are a hard core gamer.
    As an owner of a 23" Cinema Display, I have no issues with the response time of my monitor. If it is slow, I do not notice while watching video DVD's, or, while playing games- most all are action, shooters, and racing. I am very satisfied with the performance in those areas.
    As for usual computer use- word processing, photo touch up, CAD drawings, internet, etc., I only have praise for the beauty of the display, the quality of the display images, and the LARGE desktop.
    Conversely, when I bought my LCD television, response time was a very important buying point. Because of the fast pace of scene changes, high movement of sports and action movies, and viewing things like trailing news line text, fast response time makes a big difference in the overall viewing quality.
    Bottom line- with monitors, response time isn't all that matters. The following links are for your continued research (if you please):
    http://reviews.cnet.com/AppleCinema_Display_23_inch_LCD/4505-31747-30964608.html?tag=sub
    http://reviews.cnet.com/AppleCinema_Display_23_inch_LCD/4852-31747-30964608.html
    http://reviews.cnet.com/4520-3118_7-6358806-1.html
    http://www.lcdtvbuyingguide.com/lcdtv/lcdtv-responsetime.shtml
    G4AGP(450)Sawtooth, 2ghz PowerLogix, 2gbRAM, 300gbSATA+160gbATA, ATI Radeon 9800   Mac OS X (10.4.8)   Pioneer DVR-109, ExtHD 160gb x2, 23"Cinema Display, Ratoc USB2.0, Nikon Coolscan

  • Increase the time of response of my queries

    Hi, I have a db2 as database on AS400 and I would like to increase the time of response of my queries because in a table I have more of one million records.
    I select a part of this record (select * from sergt where wbtruc='A735') but to get this record where wbtruc=A735 it read the whole table so more of one million records.
    is it posssible that it read a part of table and not the whole table
    or you are another solution to increase the time of response ?
    Thanks in advance?

    Uh, oh, temporary index for 1 million records sounds
    like OutOfMemoryError :)If this query is going to be run regularly then an access path should be created on the AS400 to support it. An access path over 1 million records isn't a big deal there, the largest file we have is about 120 million records with two access paths and I'm sure there are much much bigger files in the AS400 world.

  • How to make response time of switch faster?

    on 3750, when
    1. execute ping -t command from a PC to the switch interface vlan 1 ip address,
    2. unplug the cable and plug it again,
    it takes about 30 seconds to start pinging again.
    i disabled the STP protocol and observed that; with the same procedure, recovering ping replies decreased to 3 seconds.
    is there any other tuning that i can configure and make response time even faster?
    thank you for helping :)

    Hi,
    STP convergence is typically the biggest part of host connection delays. Rather than disabling STP, you can configure "spanning-tree portfast" on the port which will achieve the same end.
    Beyond that, some of the response time delays are going to be part of MAC address learning, ARP, and the fact that the switch places a low priority on processing ICMP packets. A better test is to ping from another device _through_ the switch rather than to or from the switch.
    Here's a good document that covers various commands you can use to mitigate connectivity delays.
    Using PortFast and Other Commands to Fix Workstation Startup Connectivity Delays
    http://www.cisco.com/warp/customer/473/12.html
    HTH,
    Bobby

  • EAP-FAST - packets dropped/slow response times

    We currently have WLC's and 1131 LWAP's.  If a client is in one area (no roaming) and we carry out a constant ping, every minute a packet will either be dropped or have a huge response time (2000ms ish).
    This happens when using EAP-FAST.  If I configure the client to another SSID I have with PEAP over MsCHAP then this does not occur.
    Is there something inherrent with EAP-FAST that anyone is aware of or had this problem before?
    Thanks

    Hi Steve,
    I will make some assumptions and you tell me if they are correct
    1. When you see is the loss pings or high MS returns the phone is idle and not is use correct -
         * This is becuase the phone is "sleeping" to conserve battery life
         * If you kick off a call you will see the pings respond as normal (-150ms)
         * There is a mechanism calls PSM (Power save mode). I dont want to make this a long winded response. Simple google PSM or CAM 802.11.
    2. I dont think EAP is your issue and here is why:
         * EAP is an authentication protocol. Once authenticated your set until you need to reauthenicate again.
         * Unless of course you have an issue whereby your client is always reauth one right after another then that a different issue which isnt normal
    3. I suspect you have different DTIM settings perhaps on the different WLANs. Look under the adavnce tab and look for DTIM .. see how that is set ..
    Oh btw --If you find this helpful in anyway. Please, if you won't mind and take a second and rate the post. I would really appreciate it ! Thanks bud!

  • Browser response time slow but Analyzer fast with same query

    Hi all,
    We have a very complex query (structures and cell formulas).  When I drill and filter on a specific characteristic the action takes anything between 7 and 15 minutes when using the browser. The same query in Analyzer performing the same drilling action takes less than 35 seconds.
    Our architecture is as follows:
    - Relevant cubes are indexed on BWA
    - WebDynPro for Java
    We can see that the BWA is hit for a short time then the CPU utilization is back to 0%.  When doing '&profiling=x' on the browser I can see that the most of the time is spent on 'Get result set' / 'Get provider result set' for the Java events and on the OLAP side most time is spent on the 'Get result set' event.
    Interestingly enough - when disabling myself as a user for BIA use (NO_BIA_USE) in my user profile I get the same response time on the browser.
    So, does anyone have an idea of what may be the cause of the slow response time when using the browser?
    Thanks
    Edited by: Cobus van Rooyen on May 10, 2010 8:49 PM

    Hi,
    The reason is most likely because of the event ID 3200 where data transfer takes place from OLAP to frontend browser.
    Record a RSTT trace for this and if you are able to see frequent calls to "Apply State XML" and "Get Result Set" then apply the SAP Note 1428850. Otherwise see which function module is causing an error.
    If trace runtime is less but in browser still it takes long time then this might be because of the compression of HTPP responses, which can be confirmed by observing the sent and received data volumns from the HTTP server requests/responses. For more information refer SAP Note 746666.
    Imran...

  • Using trace response time much faster than without tracing

    Oracle 10.2.0.3 64bit for windows 2003
    one very simple statement, "delete from taba where id=**"
    when run it without tracing, took about 2 mins
    when adding 10046 trace, the response time is less than 2 seconds
    repeated this dozens times, all the same problem.
    anyone has this problem before?
    appreciate your input.

    Do you have trigger for DELETE statement on this table ?yes, 4 of them behind it
    Do you have some dependent object like materialized view using this table ?no
    Is this a single instance database or RAC database ?single instance
    Do you have concurrent DML running on this table when runnnig this tests ?no
    below if the tkprof
    TKPROF: Release 10.2.0.3.0 - Production on Thu Jan 6 12:31:57 2011
    Copyright (c) 1982, 2005, Oracle.  All rights reserved.
    Trace file: pacs_ora_5800.trc
    Sort options: default
    count    = number of times OCI procedure was executed
    cpu      = cpu time in seconds executing
    elapsed  = elapsed time in seconds executing
    disk     = number of physical reads of buffers from disk
    query    = number of buffers gotten for consistent read
    current  = number of buffers gotten in current mode (usually for update)
    rows     = number of rows processed by the fetch or execute call
    error connecting to database using: rpt3/rpt3
    ORA-12560: TNS:protocol adapter error
    EXPLAIN PLAN option disabled.
    delete TABLEAs
    where
    id=:"SYS_B_0"
    call     count       cpu    elapsed       disk      query    current        rows
    Parse        1      0.00       0.00          0          0          0           0
    Execute      1      0.00       0.01          0          3         13           1
    Fetch        0      0.00       0.00          0          0          0           0
    total        2      0.00       0.01          0          3         13           1
    Misses in library cache during parse: 1
    Misses in library cache during execute: 1
    Optimizer mode: ALL_ROWS
    Parsing user id: 36 
    Rows     Row Source Operation
          1  DELETE  TABLEAS (cr=4 pr=0 pw=0 time=706 us)
          1   INDEX UNIQUE SCAN PK_TABLEA_ID (cr=3 pr=0 pw=0 time=39 us)(object id 23307)
    Elapsed times include waiting on following events:
      Event waited on                             Times   Max. Wait  Total Waited
      ----------------------------------------   Waited  ----------  ------------
      SQL*Net message to client                       1        0.00          0.00
      SQL*Net message from client                     1        3.60          3.60
    INSERT INTO TMP_TABLEAS_TRIGGER
    VALUES
    (:B1 )
    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          1          7           1
    Fetch        0      0.00       0.00          0          0          0           0
    total        2      0.00       0.00          0          1          7           1
    Misses in library cache during parse: 0
    Optimizer mode: ALL_ROWS
    Parsing user id: 36     (recursive depth: 1)
    SELECT DISTINCT ID
    FROM
    TMP_TABLEAS_TRIGGER
    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        2      0.00       0.00          0          3          0           1
    total        4      0.00       0.00          0          3          0           1
    Misses in library cache during parse: 0
    Optimizer mode: ALL_ROWS
    Parsing user id: 36     (recursive depth: 1)
    Rows     Row Source Operation
          1  HASH UNIQUE (cr=3 pr=0 pw=0 time=158 us)
          1   TABLE ACCESS FULL TMP_TABLEAS_TRIGGER (cr=3 pr=0 pw=0 time=37 us)
    UPDATE TABLEAS SET SUPERCEDES = 0
    WHERE
    ID IN (SELECT ID FROM TABLEAAA WHERE AAID IN(SELECT AAID FROM
      TABLEAAA WHERE ID=:B1 ) ) AND SUPERCEDES=:B1
    call     count       cpu    elapsed       disk      query    current        rows
    Parse        1      0.00       0.00          0          0          0           0
    Execute      1      0.12       0.11          0      50411          2           1
    Fetch        0      0.00       0.00          0          0          0           0
    total        2      0.12       0.11          0      50411          2           1
    Misses in library cache during parse: 0
    Optimizer mode: ALL_ROWS
    Parsing user id: 36     (recursive depth: 1)
    Rows     Row Source Operation
          0  UPDATE  TABLEAS (cr=50411 pr=0 pw=0 time=117980 us)
          1   NESTED LOOPS  (cr=50411 pr=0 pw=0 time=117906 us)
      16731    VIEW  VW_NSO_1 (cr=217 pr=0 pw=0 time=17208 us)
      16731     SORT UNIQUE (cr=217 pr=0 pw=0 time=17206 us)
      16731      TABLE ACCESS BY INDEX ROWID TABLEAAA (cr=217 pr=0 pw=0 time=33524 us)
      16733       NESTED LOOPS  (cr=71 pr=0 pw=0 time=58 us)
          1        INDEX RANGE SCAN PK_TABLEA_AA (cr=3 pr=0 pw=0 time=30 us)(object id 23313)
      16731        INDEX RANGE SCAN IDX_TABLEAAA_AA_ID (cr=68 pr=0 pw=0 time=44 us)(object id 23316)
          1    TABLE ACCESS BY INDEX ROWID TABLEAS (cr=50194 pr=0 pw=0 time=90408 us)
      16730     INDEX UNIQUE SCAN PK_TABLEA_ID (cr=33464 pr=0 pw=0 time=45248 us)(object id 23307)
    UPDATE TABLEAS SET SUPERCEDEDBY = 0
    WHERE
    ID IN (SELECT ID FROM TABLEAAA WHERE AAID IN(SELECT AAID FROM
      TABLEAAA WHERE ID=:B1 ) ) AND SUPERCEDEDBY=:B1
    call     count       cpu    elapsed       disk      query    current        rows
    Parse        1      0.00       0.00          0          0          0           0
    Execute      1      0.10       0.11          0      50411          2           1
    Fetch        0      0.00       0.00          0          0          0           0
    total        2      0.10       0.11          0      50411          2           1
    Misses in library cache during parse: 0
    Optimizer mode: ALL_ROWS
    Parsing user id: 36     (recursive depth: 1)
    Rows     Row Source Operation
          0  UPDATE  TABLEAS (cr=50411 pr=0 pw=0 time=117770 us)
          1   NESTED LOOPS  (cr=50411 pr=0 pw=0 time=117660 us)
      16731    VIEW  VW_NSO_1 (cr=217 pr=0 pw=0 time=17251 us)
      16731     SORT UNIQUE (cr=217 pr=0 pw=0 time=17250 us)
      16731      TABLE ACCESS BY INDEX ROWID TABLEAAA (cr=217 pr=0 pw=0 time=33528 us)
      16733       NESTED LOOPS  (cr=71 pr=0 pw=0 time=63 us)
          1        INDEX RANGE SCAN PK_TABLEA_AA (cr=3 pr=0 pw=0 time=38 us)(object id 23313)
      16731        INDEX RANGE SCAN IDX_TABLEAAA_AA_ID (cr=68 pr=0 pw=0 time=53 us)(object id 23316)
          1    TABLE ACCESS BY INDEX ROWID TABLEAS (cr=50194 pr=0 pw=0 time=90462 us)
      16730     INDEX UNIQUE SCAN PK_TABLEA_ID (cr=33464 pr=0 pw=0 time=45175 us)(object id 23307)
    DELETE FROM TABLEAAA
    WHERE
    ID = :B1
    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          3         10           1
    Fetch        0      0.00       0.00          0          0          0           0
    total        2      0.00       0.00          0          3         10           1
    Misses in library cache during parse: 0
    Optimizer mode: ALL_ROWS
    Parsing user id: 36     (recursive depth: 1)
    Rows     Row Source Operation
          0  DELETE  TABLEAAA (cr=4 pr=0 pw=0 time=626 us)
          1   INDEX RANGE SCAN PK_TABLEA_AA (cr=3 pr=0 pw=0 time=39 us)(object id 23313)
    INSERT INTO TMP_TABLEAAA_RECORDS (AAID, STATUS,TABLEAID)
    VALUES
    (:B3 , :B2 ,:B1 )
    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          1          7           1
    Fetch        0      0.00       0.00          0          0          0           0
    total        2      0.00       0.00          0          1          7           1
    Misses in library cache during parse: 0
    Optimizer mode: ALL_ROWS
    Parsing user id: 36     (recursive depth: 2)
    SELECT DISTINCT AAID, STATUS,TABLEAID
    FROM
    TMP_TABLEAAA_RECORDS
    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        2      0.00       0.00          0          3          0           1
    total        4      0.00       0.00          0          3          0           1
    Misses in library cache during parse: 0
    Optimizer mode: ALL_ROWS
    Parsing user id: 36     (recursive depth: 2)
    Rows     Row Source Operation
          1  HASH UNIQUE (cr=3 pr=0 pw=0 time=162 us)
          1   TABLE ACCESS FULL TMP_TABLEAAA_RECORDS (cr=3 pr=0 pw=0 time=35 us)
    SELECT COUNT(*)
    FROM
    TABLEAAA WHERE AAID = :B1
    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        1      0.01       0.00          0         68          0           1
    total        3      0.01       0.00          0         68          0           1
    Misses in library cache during parse: 0
    Optimizer mode: ALL_ROWS
    Parsing user id: 36     (recursive depth: 2)
    Rows     Row Source Operation
          1  SORT AGGREGATE (cr=68 pr=0 pw=0 time=2936 us)
      16730   INDEX RANGE SCAN IDX_TABLEAAA_AA_ID (cr=68 pr=0 pw=0 time=8 us)(object id 23316)
    UPDATE TABLEAS SET SUPERCEDES = 0
    WHERE
    ID IN (SELECT ID FROM TABLEAAA WHERE AAID IN(SELECT AAID FROM
      TABLEAAA WHERE AAID=:B2 ) ) AND SUPERCEDES=:B1
    call     count       cpu    elapsed       disk      query    current        rows
    Parse        1      0.00       0.00          0          0          0           0
    Execute      1      0.29       0.29          0     121996          0           0
    Fetch        0      0.00       0.00          0          0          0           0
    total        2      0.29       0.29          0     121996          0           0
    Misses in library cache during parse: 0
    Optimizer mode: ALL_ROWS
    Parsing user id: 36     (recursive depth: 2)
    Rows     Row Source Operation
          0  UPDATE  TABLEAS (cr=121996 pr=0 pw=0 time=295237 us)
          0   HASH JOIN SEMI (cr=121996 pr=0 pw=0 time=295234 us)
          0    TABLE ACCESS FULL TABLEAS (cr=121996 pr=0 pw=0 time=295131 us)
          0    VIEW  VW_NSO_1 (cr=0 pr=0 pw=0 time=0 us)
          0     MERGE JOIN CARTESIAN (cr=0 pr=0 pw=0 time=0 us)
          0      TABLE ACCESS FULL TABLEAAA (cr=0 pr=0 pw=0 time=0 us)
          0      BUFFER SORT (cr=0 pr=0 pw=0 time=0 us)
          0       INDEX RANGE SCAN IDX_TABLEAAA_AA_ID (cr=0 pr=0 pw=0 time=0 us)(object id 23316)
    UPDATE TABLEAS SET SUPERCEDES = 0
    WHERE
    ID=:B1
    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          3          0           0
    Fetch        0      0.00       0.00          0          0          0           0
    total        2      0.00       0.00          0          3          0           0
    Misses in library cache during parse: 0
    Optimizer mode: ALL_ROWS
    Parsing user id: 36     (recursive depth: 2)
    Rows     Row Source Operation
          0  UPDATE  TABLEAS (cr=3 pr=0 pw=0 time=33 us)
          0   INDEX UNIQUE SCAN PK_TABLEA_ID (cr=3 pr=0 pw=0 time=30 us)(object id 23307)
    UPDATE TABLEAS SET SUPERCEDEDBY = 0
    WHERE
    ID IN (SELECT ID FROM TABLEAAA WHERE AAID IN(SELECT AAID FROM
      TABLEAAA WHERE AAID=:B2 ) ) AND SUPERCEDEDBY=:B1
    call     count       cpu    elapsed       disk      query    current        rows
    Parse        1      0.00       0.00          0          0          0           0
    Execute      1      0.26       0.29          0     121996          0           0
    Fetch        0      0.00       0.00          0          0          0           0
    total        2      0.26       0.29          0     121996          0           0
    Misses in library cache during parse: 0
    Optimizer mode: ALL_ROWS
    Parsing user id: 36     (recursive depth: 2)
    Rows     Row Source Operation
          0  UPDATE  TABLEAS (cr=121996 pr=0 pw=0 time=290701 us)
          0   HASH JOIN SEMI (cr=121996 pr=0 pw=0 time=290697 us)
          0    TABLE ACCESS FULL TABLEAS (cr=121996 pr=0 pw=0 time=290563 us)
          0    VIEW  VW_NSO_1 (cr=0 pr=0 pw=0 time=0 us)
          0     MERGE JOIN CARTESIAN (cr=0 pr=0 pw=0 time=0 us)
          0      TABLE ACCESS FULL TABLEAAA (cr=0 pr=0 pw=0 time=0 us)
          0      BUFFER SORT (cr=0 pr=0 pw=0 time=0 us)
          0       INDEX RANGE SCAN IDX_TABLEAAA_AA_ID (cr=0 pr=0 pw=0 time=0 us)(object id 23316)
    UPDATE TABLEAS SET SUPERCEDEDBY = 0
    WHERE
    ID=:B1
    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          3          0           0
    Fetch        0      0.00       0.00          0          0          0           0
    total        2      0.00       0.00          0          3          0           0
    Misses in library cache during parse: 0
    Optimizer mode: ALL_ROWS
    Parsing user id: 36     (recursive depth: 2)
    Rows     Row Source Operation
          0  UPDATE  TABLEAS (cr=3 pr=0 pw=0 time=42 us)
          0   INDEX UNIQUE SCAN PK_TABLEA_ID (cr=3 pr=0 pw=0 time=40 us)(object id 23307)
    SELECT CLASSIFICATION
    FROM
    TABLEAS WHERE ID=:B1
    call     count       cpu    elapsed       disk      query    current        rows
    Parse        0      0.00       0.00          0          0          0           0
    Execute      1      0.00       0.00          0          0          0           0
    Fetch        1      0.00       0.00          0          3          0           0
    total        2      0.00       0.00          0          3          0           0
    Misses in library cache during parse: 0
    Optimizer mode: ALL_ROWS
    Parsing user id: 36     (recursive depth: 2)
    rollback
    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          2         31           0
    Fetch        0      0.00       0.00          0          0          0           0
    total        2      0.00       0.00          0          2         31           0
    Misses in library cache during parse: 0
    Parsing user id: 36 
    Elapsed times include waiting on following events:
      Event waited on                             Times   Max. Wait  Total Waited
      ----------------------------------------   Waited  ----------  ------------
      log file sync                                   1        0.00          0.00
      SQL*Net message to client                       1        0.00          0.00
      SQL*Net message from client                     1       14.18         14.18
    alter session set events '10046 trace name context off'
    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        0      0.00       0.00          0          0          0           0
    total        2      0.00       0.00          0          0          0           0
    Misses in library cache during parse: 0
    Parsing user id: 36 
    OVERALL TOTALS FOR ALL NON-RECURSIVE STATEMENTS
    call     count       cpu    elapsed       disk      query    current        rows
    Parse        3      0.00       0.00          0          0          0           0
    Execute      3      0.00       0.01          0          5         44           1
    Fetch        0      0.00       0.00          0          0          0           0
    total        6      0.00       0.01          0          5         44           1
    Misses in library cache during parse: 1
    Misses in library cache during execute: 1
    Elapsed times include waiting on following events:
      Event waited on                             Times   Max. Wait  Total Waited
      ----------------------------------------   Waited  ----------  ------------
      SQL*Net message to client                       3        0.00          0.00
      SQL*Net message from client                     3       14.18         24.44
      log file sync                                   1        0.00          0.00
    OVERALL TOTALS FOR ALL RECURSIVE STATEMENTS
    call     count       cpu    elapsed       disk      query    current        rows
    Parse       12      0.00       0.00          0          0          0           0
    Execute     13      0.79       0.82          0     344825         28           5
    Fetch        6      0.01       0.00          0         77          0           3
    total       31      0.81       0.82          0     344902         28           8
    Misses in library cache during parse: 0
       16  user  SQL statements in session.
        0  internal SQL statements in session.
       16  SQL statements in session.
        0  statements EXPLAINed in this session.
    Trace file: pacs_ora_5800.trc
    Trace file compatibility: 10.01.00
    Sort options: default
           1  session in tracefile.
          16  user  SQL statements in trace file.
           0  internal SQL statements in trace file.
          16  SQL statements in trace file.
          16  unique SQL statements in trace file.
        1066  lines in trace file.
          18  elapsed seconds in trace file.Edited by: OracleExplorer on Jan 21, 2011 8:40 PM

  • Anyway to speed up the response time of E62/E61?

    I bought the E62 and found it is considerably slower than most smart phones specially when compared with Blackberry andsets. It really takes a while to open the mails or applications/folders.
    Is there any way we can improve the response time for E62?

    You aren't by any chance calling a function in your repeating frame that in turn goes back and queries the database, are you? If so ... don't. We regularly do 500+ page PDF-file reports, and one thing we discovered early on was that repeatedly going back to the database while generating the report output (in our case, in calculations that were being done on each line of a report) slowed the output down by an order of magnitude. Instead, we now retrieve all the data needed for each report up front (via functions or views called in the initial SQL for the report), and just use Reports to format the output. MUUUUUUUCH faster -- 200 page reports that used to take 15 minutes to complete now complete in just seconds.
    One way you can visually see if this is part of your problem is to watch the report execute in the Report Queue Manager application. If it spends all its time on the "Opening" stage then breezes through each page, this is not your problem. If instead it seems to take a long time generating each page, I'd suspect that this may be at least part of your delay.
    - Bill

  • Response time much more in migrated AIX database than in Windows database

    We migrated a 9.2.0.6 database from windows to AIX (on same oracle version). Initially we were getting really slow response on direct sqls and batch sqls fom application server. Then we tuned aix database a bit and got a better response time for direct sqls on aix database.
    Now queries run faster on aix database than the db on windows.
    However, the queries from applciation (ACCURATE application) are still twice slower on aix database compared to windows database.
    Can anyone suggest a possible cause or tuning area?
    We have checked on network level and found no bottlenecks.
    Regards,
    Garima

    user650817 wrote:
    We migrated a 9.2.0.6 database from windows to AIX (on same oracle version). Initially we were getting really slow response on direct sqls and batch sqls fom application server. Then we tuned aix database a bit and got a better response time for direct sqls on aix database.
    Now queries run faster on aix database than the db on windows.
    However, the queries from applciation (ACCURATE application) are still twice slower on aix database compared to windows database.
    Can anyone suggest a possible cause or tuning area?Garima,
    if you have particular queries that you know of that are behaving differently, you could start right away by comparing the execution plans and tracing the execution using the SQL trace facility and the "tkprof" trace file analyzer.
    If you want to get an overview of the database performance, you should consider installing STATSPACK on both systems if you haven't done so yet and create snapshots to compare statspack reports from both systems for a representative time period. This way you can gather information about the top wait events and top SQLs of the periods analyzed.
    By the way, how did you "migrate" the database? Did you use export/import to migrate? What about the statistics for the cost based optimizer, could these be different between the two systems or are you still using the rule based optimizer?
    Regards,
    Randolf
    Oracle related stuff blog:
    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/

Maybe you are looking for

  • How can I get null values for the later weeks

    Hi All, When I execute this code I get the records till current week. How can I display the output so that I get null values for the later weeks. (with the help of v_numOfWeeks variable in the code) Thanks, Vikram DECLARE    v_query VARCHAR2(4000);  

  • HELP! iTunes Crashes On Launch Every Time

    Okay, so last night I updated to 10.6.3. A couple hours later, I closed down iTunes and opened it back up to discover that it wouldn't open anymore. I tried removing the library file, thinking it might have become corrupted somehow, and iTunes would

  • Mac book retina display - compatibility with PSE12?

    I'm just going to have to keep on posting until i get an answer.  Software and pictures are blurry - PSE12 clearly not compatible with macbook pro retina display. Is there a fix? Or do i need to buy ANOTHER version of PSE??? adobeelements

  • Help! Lost all Data!

    Problem with logging on: Started up and window appeared asking for my user log on password. Computer seemed to recognize password but got this message: This user cannot log in at this time. Password hint is correct, but can't log in after several tri

  • Function to search a Strings within Arrays

    Hi all, trying to make a soccer tournement management system primarily using Java with NetBeans. Having trouble finding info on a how to function. Would like to search either - last name - first name - by suburb - player jersey number. (search int, i