How to calculate #Buffer Gets    # Exec           Buffer Gets/Exec

Hi,
How to calculate #Buffer Gets,# Execution time,Buffer Gets/Exec for a sql query?

Nirmal
You can find out these statistics from two places
1) using SQL_TRACE (10046 trace) and then TKPROF (or Autotrace in SQL*Plus)
2) or looking at V$SQL which records the cost assigned to each SQL statement since the statement was first cached.
If you use Statspack or AWR, you can see the difference between two points in time, so you can calculate the cost for a period of time.
See Using SQL_Trace and TKPROF
http://download-uk.oracle.com/docs/cd/B10501_01/server.920/a96533/sqltrace.htm#1018
and Using Statspack
http://download-uk.oracle.com/docs/cd/B10501_01/server.920/a96533/statspac.htm#34837
(see the 10g documentation equivalents if necessary).
Remember, ratios (eg gets/exec) aren't always very helpful. You're best off concentrating on those operations which take longest (ie where there is the most potential to save time). See (eg) www.hotsos.com, www.oraperf.com, and others to identify effective performance methodologies.
HTH
Regards Nigel

Similar Messages

  • Rolliing backword window. How to calculate and get op like this

    I have date as below
    with abc as (select 1 userid, 11 clo_id, to_date('05/01/2009', 'dd/mm/yyyy') c_date, 216 ilo_id, to_date('06/01/2009', 'dd/mm/yyyy') i_date from dual union all
                 select 1 userid, 11 clo_id, to_date('05/01/2009', 'dd/mm/yyyy') c_date, 215 ilo_id, to_date('05/01/2009', 'dd/mm/yyyy') i_date from dual union all
                 select 1 userid, 11 clo_id, to_date('05/01/2009', 'dd/mm/yyyy') c_date, 214 ilo_id, to_date('04/01/2009', 'dd/mm/yyyy') i_date from dual union all
                 select 1 userid, 11 clo_id, to_date('05/01/2009', 'dd/mm/yyyy') c_date, 213 ilo_id, to_date('04/01/2009', 'dd/mm/yyyy') i_date from dual union all
                 select 1 userid, 11 clo_id, to_date('05/01/2009', 'dd/mm/yyyy') c_date, 212 ilo_id, to_date('03/01/2009', 'dd/mm/yyyy') i_date from dual union all
                 select 1 userid, 11 clo_id, to_date('05/01/2009', 'dd/mm/yyyy') c_date, 211 ilo_id, to_date('02/01/2009', 'dd/mm/yyyy') i_date from dual)
    select *
    from   abc
    USERID     CLO_ID      C_DATE                       ILO_ID  I_DATE           
             1         11 05/01/2009 00:00:00        216 06/01/2009 00:00:00
             1         11 05/01/2009 00:00:00        215 05/01/2009 00:00:00
             1         11 05/01/2009 00:00:00        214 04/01/2009 00:00:00
             1         11 05/01/2009 00:00:00        213 04/01/2009 00:00:00
             1         11 05/01/2009 00:00:00        212 03/01/2009 00:00:00
             1         11 05/01/2009 00:00:00        211 02/01/2009 00:00:00
    Now i want to calculate rolling backword frequency of each ilo id and output should come like as based Frequency winodw
    e.g. if frequency window is 2 then
    USERID   CLO_ID C_DATE                     ILO_ID  I_DATE                        FREQUENCY
             1         11 05/01/2009 00:00:00        216 06/01/2009 00:00:00          2
             1         11 05/01/2009 00:00:00        215 05/01/2009 00:00:00          3
             1         11 05/01/2009 00:00:00        214 04/01/2009 00:00:00          3
             1         11 05/01/2009 00:00:00        213 04/01/2009 00:00:00          2
             1         11 05/01/2009 00:00:00        212 03/01/2009 00:00:00          2
             1         11 05/01/2009 00:00:00        211 02/01/2009 00:00:00          1
    1. For each ILO ID, go back number od days given as Frequency window (in our case its 2)
    2. calculate the number of ilo_id in that range
    3. number of ilo_id is the frequency of that ilo_idHow can i achieve this.
    Edited by: Kuldeep2 on Sep 29, 2010 2:30 AM
    Edited by: Kuldeep2 on Sep 29, 2010 2:33 AM

    Use analytic COUNT:
    variable frequency number
    exec :frequency := 2;
    with abc as (select 1 userid, 11 clo_id, to_date('05/01/2009', 'dd/mm/yyyy') c_date, 216 ilo_id, to_date('06/01/2009', 'dd/mm/yyyy') i_date from dual union all
    select 1 userid, 11 clo_id, to_date('05/01/2009', 'dd/mm/yyyy') c_date, 215 ilo_id, to_date('05/01/2009', 'dd/mm/yyyy') i_date from dual union all
    select 1 userid, 11 clo_id, to_date('05/01/2009', 'dd/mm/yyyy') c_date, 214 ilo_id, to_date('04/01/2009', 'dd/mm/yyyy') i_date from dual union all
    select 1 userid, 11 clo_id, to_date('05/01/2009', 'dd/mm/yyyy') c_date, 213 ilo_id, to_date('04/01/2009', 'dd/mm/yyyy') i_date from dual union all
    select 1 userid, 11 clo_id, to_date('05/01/2009', 'dd/mm/yyyy') c_date, 212 ilo_id, to_date('03/01/2009', 'dd/mm/yyyy') i_date from dual union all
    select 1 userid, 11 clo_id, to_date('05/01/2009', 'dd/mm/yyyy') c_date, 211 ilo_id, to_date('02/01/2009', 'dd/mm/yyyy') i_date from dual)
    select  abc.*,
            count(ilo_id) over(order by i_date range between :frequency - 1 preceding and current row) cnt
      from  abc
      order by i_date desc
        USERID     CLO_ID C_DATE        ILO_ID I_DATE           CNT
             1         11 05-JAN-09        216 06-JAN-09          2
             1         11 05-JAN-09        215 05-JAN-09          3
             1         11 05-JAN-09        214 04-JAN-09          3
             1         11 05-JAN-09        213 04-JAN-09          3
             1         11 05-JAN-09        212 03-JAN-09          2
             1         11 05-JAN-09        211 02-JAN-09          1
    6 rows selected.
    SQL> SY.

  • CFM /TR - how system calculate amount based on rate FX 60A

    Hi all,
    i need to know how system calculates amount based on rate entered upon creating a contract (t-code TX01).
    steps input:-
    1. header - comp code, product type, trans type
    2. partner
    3. purchase curr & amount (eg. IDR 8,345,545,500)
    4. sale currency only (amount system will auto calculate) USD
    5. rate field = 11.553
    6. spot rate will auto pick up from rate
    7. value date
    8. contract date
    upon TBB1 no error. posting log as follows:-
    FX1000+ : 40 8,345,545,500 IDR bank GL acc
                    50 8,345,545,500 IDR clearing acc
    FX2000- : 40 722370.42 USD clearing acc
                   50 722370.42 USD bank GL acc
    but upon TPM18 error occurred as follows:
    DBT_C009 - GL not maintain in acc symbol 5.3.4
    DBT_E039 - no posting spec assigned to update type
    DBT_B018 : 40 0 USD, 431,977,511 IDR gain/loss
                       50 0 USD, 431,977,511 IDR clearing acc
    so, after maintained DBT_C009 as follows still error for DBT_E039:
    40  0 USD, 38 IDR clearing acc
    50  0 USD, 38 IDR P&L gl acc
    what i don't understand is how system calculate and get DBT_C009 & DBTE039.
    what is the function of TPM18?
    thanks.

    Hello Prarnod,
    I have done the first node only for actuals that come from the integration to the internal order.
    I have tried setting up 2 and 3 even though the 3rd one does not make any sense to me
    Thanks,
    Paul

  • How to Calculate AGE by getting difference between two Date Fields

    HI Gems
    I need to calculate AGE from getting difference from two date fields. But when i am trying to wrte fromula as Current date - date1(some date field) then it is showing error.
    How can i get values.
    Thanks
    Manu

    You already asked this question:
    How to calculate AGE from two different date fields

  • How an SSCC number gets generated

    Hi Gurus,
    I am now learning HUM. Actually I dont have access to client system. I am working on sandbox and I want to know how an SSCC number gets generated. I checked Number range object LE_SSCC. I did not not understand the relevence because in LE_SSCC, current number is 290 and the Internal HU number is 1500. Number range object HU_VEKP is working fine with internal HU Number. The SSCC numbers are incremented some times with 7 and some times with 17. No where I could see the source settings for this.
    I hope that SSCC Number is copied from the box sent by vendor through bar code readear. If that is the case it should be randomly changing. There should not be any fixed increment. What is the guarentee that it is not repeated?
    Please throw some light on SSCC Number generation.

    Hi Nagesh,
    You define the number range in t-code SNRO. You can define an external number range there for you vendor received SSCC numbers. The skipping in the number range can occur baseed upon what is in the number range buffer in SAP. When you log in you are assigned numbers from the number range and when someon else signs in they are assigned numbers from the range. These numbers may not be sequential.
    Regards,
    Steve

  • In Hyperion essbase how the project will get allocated?

    Hi All:
    I am new to the Hyperion; I have an doubt how hyperion project will devide into the modules? kindly take an example any finanical large project and tell me.
    In normally 1. Functional designs, Technical designs, Build, testing. in normal any project.
    But hyperion how it will be? could you pls tell me?
    Also what kind of daily activites we get in Hyperion Essbase?

    Please check out this thread => How to calculate cache setting from Essbase application.
    The ODTUG whitepaper is indeed quite good.
    Thank you,
    Todd Rebner

  • How do I only get certain questions appear in the quiz results?

    I have created a course through Captivate 6, throughout the course there are questions to guage the learners attention. There is also a quiz at the end. However, captivate includes on the questions throughout the course on the quiz results which I do not want to happen.
    Can anyone advise how I can only get certain questions appear on the quiz results please?

    Branch aware turns off the playbar in 6 (not in 7 any more, at least not for me).
    Could you explain more in detail what you want, because I don't understand it. You want the user to answer all questions, but the score should only show what? If you don't want some questions to have a score added to the Quiz total, you can indicate that in the Properties of that Question slide.
    And please, tell the exact number (3 versions of 6), and also if you have to report to a LMS?
    Lilybiri

  • I downloaded a new version of firefox. It said it had problems with my norton toolbar and now it doesn't feature it in the window. I'm not that comp savvy. How do I either get the Norton toolbar up or go back to the old firefox? Thank you.

    I downloaded a new version of firefox. It said it had problems with my norton toolbar and now it doesn't feature it in the window. I'm not that comp savvy. How do I either get the Norton toolbar up or go back to the old firefox? Thank you.

    Please authorize ADE 3 with same credentials that you used with older version of ADE

  • I can't see an app on my iphone, but when i search i get it. i've made room for the icon to show up on screen, but how do i actually get the icon to appear?

    I can't see an app on my iphone, but when i search i get it. i've made room for the icon to show up on screen, but how do i actually get the icon to appear?

    On your iPad, just go to Settings>Mail, Contacts, etc.>Add account>iCloud and put in the details of the account you set up.  Shouldn't be a problem at all.

  • I changed my Apple ID but my iTunes hasn't updated so I can't access it...do I need to reset all devices to factory settings? or how else do I get the iTunes to link to Apple ID?

    I updated my Apple ID primary email address without having switched off 'Find my....' on all devices. A 2 hour very helpful call with Apple Support solved ny Apple ID and ICloud. Later, I tried to update apps but my iTunes account is still on the old ID and I can't access that email/password anymore. I can't get a support appointment for 48 hours but need to update travel apps soon!
    Do I need to reset to factory settings on all devices (5!) and start again...or how else can i get iTunes to link to my Apple ID now?
    Any help appreciated!

    Thanks, David. But that was the first thing I tried. For some reason, when I try to change my Apple ID back to my old email address, I get the message that that Apple ID is already in use and so I cannot use it! I have tried requesting a password reset using my old Apple ID email, but I've waited and waited and nothing has come to my old email address. This is sooooooo frustrating!

  • Save password? how the **** can I get rod of this function!!! every time I sign to a place if I wanted to safe a bloody password I would do that!!!

    save password? how the **** can I get rod of this function!!! every time I sign to a place if I wanted to safe a bloody password I would do that!!!

    It is the same in the latest version 7.0.2. You can shut off the saving and auto filling of passwords by clicking in the menu bar at the top Safari > Preferences and then select Autofill and uncheck the passwords box. Also check the next pane as well.

  • I bought a relative's original iPad. I want to leave the apps on it and add my own pdfs to read. My itunes account is really for my iPod. the computer says that if I "Sync" the iPad will be erase, and become like my iPods. how can I just get my files onto

    I am a first-time iPad owner/user. I bought a relative's original iPad. I want to leave the apps on it and add my own pdfs to read. My itunes account is really for my iPod. iTunes message says that if I "Sync" the iPad will be erase, and become like my iPods. If I make a new iTunes account, would the apps be erased when I tried to use it?
    How can I just get my files onto this iPad, and still have the apps that my relative left there for me?
    Thank you.

    iPads sync to 1 computer only.
    All media and apps are tied to the Apple ID that purchased them.
    Without your relatives ID and password, you cannot update any of the Apps.
    I am pretty certain he is also violating Apples terms of service by giving you the apps.

  • I have an iPhone5 16 gb and a 120 gb iPod. All my songs won't fit on the iPhone of course. How can I just get some of them on the iPhone? I want to keep all my music on the iPod. I am VERY new to all this so be gentle and thanks.

    I have an iPhone5, 16 gb and a 120 gb iPod. All my songs won't fit on the iPhone of course. How can I just get some of them on the iPhone? I want to keep all my music on the iPod, but just want SOME of my music on the iphone. I am VERY new to all this so be gentle and thanks.

    You Sync the Music you want on the Phone via iTunes on your computer.
    See here  >  http://support.apple.com/kb/HT1386
    From Here  >  http://www.apple.com/support/iphone/syncing/

  • How to use SET & GET Parameters in Module Pool

    Hi Friends,
    Can anyone please tell how to use SET / GET parameters and PARAMETER ID for a text box (Input / Output field ) in module pool? What is the purpose and where do we need to do coding for it?
    Note : I will definitely give the marks for good responses.
    Thanks in advance,
    Pradeep

    Hi Pradeep,
    You can save values in the SAP memory using a parameter ID. These
    are user and terminal-session specific, but available to all internal and
    external sessions.
    SET Parameter copies the corresponding field contents into the SAP
    System memory in the PAI processing block.
    GET Parameter copies the corresponding field contents from the SAP
    memory at the end of the PBO processing block, after data has been
    transferred from the program, if the screen field still has its initial value
    You can link an input/output field to an area of the SAP memory in the
    ABAP Dictionary.
    When you use an input/output field that is defined in the ABAP
    Dictionary, its parameter ID is displayed in the Dictionary attribute
    Parameter ID in the Screen Painter.
    Usage
    SET PARAMETER ID: ’CAR’ FIELD space,
    ’CON’ FIELD space,
    ’DAY’ FIELD space.
    Here is the link that explains the usage of GET/SET in detail
    <a href="http://help.sap.com/saphelp_erp2005vp/helpdata/en/9f/db9e0435c111d1829f0000e829fbfe/content.htm">http://help.sap.com/saphelp_erp2005vp/helpdata/en/9f/db9e0435c111d1829f0000e829fbfe/content.htm</a>
    Regards,
    Sharadha

  • How do I stop getting email notifications from Apple. I have checked all of the "no" boxes. Help!

    How do I stop getting email notifications from Apple support. I have checked all the "no" boxes. Help!

    https://discussions.apple.com/docs/DOC-3661
    Message was edited by: deggie

Maybe you are looking for

  • How to share files between two accounts on the same Macbook Pro???

    Hi, I have recently purchased a Macbook Pro and have created two accounts, one for me and one for my wife. I have all the itunes music on my account and my wife wants to load some of the songs nto her Itunes on her account but I don't want to start c

  • Get wrong bookmark levels when converting Word to PDF using Acrobat 7.0

    I am using MS Word 2003, Windows XP and Adobe Acrobat 7.0. When converting a DOC to PDF, all features are perfect except the bookmarks are located at the wrong level, i.e., the first chapter "Introduction" is the first level, which is desired; but th

  • Displaying BLOB images from table in a report

    I am trying to upload images to a table, display them in a report afterwards. I have succeeded in the first part, but not in the second.<br> <br> I can display images in a report if they are in located in wwv_flow_file_objects$ where they are automat

  • Providers co-existing

    This is from the JMS specification: A provider must be prepared to accept, from a client, a message whose implementation is not one of its own. A message with a �foreign� implementation may not be handled as efficiently as a provider�s own implementa

  • Can't use RSA1 to transport Query

    Hello Experts, I made some coding changes to an existing query. I generated the infoset and user group to create a transport request to send to the test system. The changes works fine in the development system but they do not work in the test system.