Difference between FOR UPDATE NOWAIT and no FOR UPDATE NOWAIT

Hi,
I have a quick question relating to the difference in SELECT statements and the use of FOR UPDATE NOWAIT.
Example:
If I query the following
SELECT * FROM ZX_LINES WHERE APPLICATION_ID = :B4 AND ENTITY_CODE = :B3 AND EVENT_CLASS_CODE = :B2 AND TRX_ID = :B1
/ with binds parsed, the result in Autotrace is as follows:
consistent gets     87
consistent gets - examination     2
consistent gets from cache     87
However, if I query the following
SELECT * FROM ZX_LINES WHERE APPLICATION_ID = :B4 AND ENTITY_CODE = :B3 AND EVENT_CLASS_CODE = :B2 AND TRX_ID = :B1
FOR UPDATE NOWAIT
/ the results in Autotrace are:
consistent gets     4341
consistent gets - examination     2
consistent gets from cache     4341
db block changes     5894
db block gets     5920
db block gets from cache     5920
So, I'm trying to understand why it happens that a FOR UPDATE NOWAIT requires so many more consistent gets, as opposed to not using a FOR UPDATE?

>
So, I'm trying to understand why it happens that a FOR UPDATE NOWAIT requires so many more consistent gets, as opposed to not using a FOR UPDATE?
>
The main difference is that when you use FOR UPDATE Oracle has to LOCK each row.
How many rows will your query return?
Did you notice that in the second example ALL of the consistent gets were from the cache?
Did you notice all of the block gets? And that ALL of them were from the cache?

Similar Messages

  • Differences between Headstart Oracle Designer and Headstart for Apps

    Hello,
    I would like to know where i can find an online demonstration of the product "Headtsart for Apps 11i" ?
    I have found the online demonstration of the product "Headtsart Oracle Designer" at the url :
    http://otn.oracle.com/products/headstart/headstartdemo_viewlet.html
    I would like to compare the functionalities of these two products (the tabs option for example).
    For a new application, we have the choice between "Headstart for apps"+"Oracle Application" environment or "Headstart Oracle Designer" alone.
    If no demonstration exists, could you tell me the difference between these two products (i have understood that one run under OA and the other run alone) ?

    Hi,
    Headstart for Apps and Headstart Oracle Designer are based on the same idea, and therefore there are many similarties between the two. The main differences are:
    * the look and feel
    Headstart for Apps is used to generate Oracle Form screens with the same look and feel as a standard Oracle Application screen. Headstart Oracle Designer has its own look and feel.
    Headstart for Apps also enables/eases some Oracle Applications specific look and feel features (although Headstart Oracle Designer has also adopted some of these).
    * dependency of Oracle Applications
    Forms generated with Headstart for Apps cannot run outside the Oracle Applications framework. You will use the same security mechanism as for an Oracle Applications form, the same messaging system, and you can use the standard Oracle Applications built ins.
    Headstart Oracle Designer runs completely outside the Oracle Applications framework, there is a separate messaging system, and you cannot use the Oracle Applications built ins.
    Hope this helps!

  • Is there any difference between sun solaris 8 and windows for Garb.Collecti

    Hi All,
    is there any difference between refreshing the java virtual memory between sun solaris 8 and windows.i am fetching 25 records for every search action.in windows usage of java virual memory is 5 mb after every search it refreshes the memory.while using the same code in sun solaris 8 it throws heap out of memory error and for every search it wont refresh the memory.

    Some other related links
    http://java.sun.com/docs/hotspot/gc5.0/gc_tuning_5.html
    http://e-docs.bea.com/wls/docs81/perform/JVMTuning.html

  • Difference between open,fetch,close and a for loop

    Is there much difference in looping a query using fetch loop or a for loop?
    Example:
    For x in (select * from ....) loop
    end loop;
    and
    OPEN c_cursor;
    LOOP
    FETCH c_cursor INTO myVar;
    EXIT WHEN c_cursor%NOTFOUND;
    END LOOP;
    close c_cursor;
    Let's say we have a few thousand users using a function that uses this code. Would you see much difference in speed? Suppose i forget to close the cursor in the second example. Will that be a major issue if we have a very large userbase or with oracle close the cursor themself after a while? The cursor wont lock the record, right? So even if we forget to close the cursor we won't get a deadlock i suppose. Only if we declare the cursor for update but that's not the case.

    simple test case to prove the point
    SQL> create or replace function myFunc return number
      2  is
      3     cursor mycursor
      4     is
      5     select * from dual;
      6
      7     myvar dual.dummy%type;
      8  Begin
      9     open myCursor;
    10
    11     fetch myCursor into myVar;
    12
    13
    14     if myCursor%found
    15     then
    16
    17             return 1;
    18     else
    19             return 0;
    20     end if;
    21
    22
    23     close myCursor;
    24  end;
    25  /
    Function created.
    SQL> show parameter open_cursor
    NAME                                 TYPE        VALUE
    open_cursors                         integer     300
    SQL>
    SQL> select myfunc from dual connect by level <= 350
      2  /
        MYFUNC
             1
             1
             1
             1
             1
             1
             1
             1
             1
             1
             1
    350 rows selected.
    SQL>See i dont hit any error

  • I did re-set my password and when I click on Install for Mavericks, I still get a box for "administrator password" and it still won't accept my new password. Is there a difference between my Apple ID and the administrator password they're asking for?

    I downloaded Mavericks and it won't install. I did re-set my password and when I click on Install for Mavericks, I still get a box for "administrator password" and it still won't accept my new password. Is there a difference between my Apple ID and the administrator password they're asking for? I never had an administrator password-- I just hit enter and have never had a problem before with previous installations. I'm on an iMac, from 2007, running Mt. Lion (version 10.8.5). I've been looking for other's posts who may be having the same problem, but haven't found any. Can anyone help?

    Ugh. The 'no password, no work' thing is a recent Apple development. I ran into it on my system and ended up having to do a clean install on a partition I fully erased.
    I suppose, if you have the ability to, go online and look up how to burn a bootable DVD image. Download the 10.8.4 image then use the Disk Utility to make a boot image of it. You'll need a dual-layer DVD or a USB drive (or memory stick at least 8GB) If you've got an optical drive, burn the disk, if you've a USB device, use that.
    Then get a pocket drive and copy your important files off the system or let Time Machine do a full backup.
    When the backup is done, insert the disk and hold down the C key until the machine boots off of the DVD. At the point you get to the start window, go to the menu and choose the Disk Utility.
    In the Disk Utility, reformat the drive. You go to the actual DRIVE (not the Macintosh HD, but the root above it that is the actual hard drive device)
    I always do this and *partition* it into several volumes, the benefit being, you can store all of your music, documents and importans stuff on that secondary storage volume you make - it will have it's own index and then the first volume is where you put the OS and it will have it's own index as well. That way, if the OS throws a wobbler and you need to reinstall, you don't lose your data.
    Depending on the size of your hard drive, it is good to give your OS partition at least 60GB and optimally 100GB, and the rest for storage.
    Name your volumes, use the little box sliders to manually size them or put that number in the size window, select for the format, Mac OS Extended (Journaled) and hit Apply and then the Disk Utility will quickly create your new partitions.
    Once finished, quit the Utility and it will return you to the OS installer. Select the volume you want to install to and it should start up and install.
    Once the installation is done, you'll get the new machine startup then you MUST put in a password for the computer. Once you're in, and to the desktop, don't bother with any Mountain Lion updates, go right to the App Store and get the Mavericks update and let it install the app to your Applicaitons folder, then do that install.
    On a side note, there MAY be a way to make a disk image from the Mavericks application and avoid the entire Mountain Lion step.. I honestly do not know, but a bit of hitting the search engines may find out if there is. I think that if you looked for "make Mavericks boot disk or boot image' you may find something.
    Good luck!

  • Difference between Crsytal Report 2011 and Crystal Report for Enterprise 4

    difference between Crystal Report 2011 and Crystal Report for Enterprise 4.0?
    I think Crystl Reprt 2011 has more function, is it right?

    Hi,
    I recently attended a SAP Virtual trianing on SAP Business Objects BI 4.0.
    Here are few extracts from that which probably shows some light to you:
    SAP Crystal Reports 2011
    1. UI and associated processing servers remain the same as CR 2008
    2. Incremental update to CR 2008 with a few new features*
    3. Continue to provide current CR 2008 functionality as-is for existing customers
    SAP Crystal Reports for Enterprise 4.0
    1. Major update & redesign of the Crystal Reports Designer and associated processing servers
    2. Focus on streamlined report design, reporting against BI 4.0 Universe, & reporting against SAP BW data
    3. Provide the foundation for all future releases of Crystal Reports
    Differences between these two releases:
    Data Source & Usage Type                                       General Recommendation
    1. SAP BusinessObjects BI 4.0                                        SAP Crystal Reports Relational Universe (UNX) for Enterprise
    OLAP Universe (UNX)
    2. SAP NetWeaver BW 7 BEx Query (BICS)                    SAP Crystal Reports for Enterprise
    3. SAP NetWeaver BW 3.5 BEx Query                             SAP Crystal Reports 2011
    4. SAP Profitability Cost Management                              SAP Crystal Reports for Enterprise through Analysis View
    SAP Strategy Management
    SAP Budget, Planning and Consolidation
    SAP Extended Analytics
    5. Platform Driven Alerting                                                SAP Crystal Reports for Enterprise
    6. Business Views                                                           SAP Crystal Reports 2011
    7. Direct RDBMS or OLAP access                                    SAP Crystal Reports 2011
        SAP ERP/ Live Office Content/
        Enterprise search content
    Regards
    Gowtham

  • Difference between SAP 4.7 and ECC 6.0   for mm

    hi sap guru ,
    Difference between SAP 4.7 and ECC 6.0   mm point of view
    4.7 already implemented  now  upgradetion  to 6.0 what is  major role  as a mm consultant,
    thanks
    biswa

    Hi,
    check the links for complete info
    vimp link
    http://erp.fmpmedia.com/Default.aspx?alias=erp.fmpmedia.com/english
    Here select source Release version as SAP R/3 and Target version as SAP ERP 6.0, solution area as "Procurement and logistics execution" then Module as "MM"
    click on "Search"
    U will get the complete info
    ECC 6 has new gl ledger concept which is different for 4.7
    version in the folloiwng manner.
    1. It enables Business area posting - Segment reporting
    made easy
    2. Profit centre accounting is through new GL
    3. Split of entry to post assets and liabilities to
    respective profit centres. (Balance sheet items)
    4. Enables commitment of FM
    http://www.allinterview.com/showanswers/71032.html
    Edited by: Mohd Uzair Hussain on Mar 11, 2010 9:58 PM

  • In the middle of downloading an update for garage band and lost the connection, now the app won't open or finish the download.  Can I reinstall the app without losing my music?

    In the middle of downloading an update for garage band and lost the connection, now the app won't open or finish the download.  Can I reinstall the app without losing my music?

    The obvious way to resolve this on a computer would be to uninstall the app, then reinstall it, however on an iOS device that would cause all the data assoicated with the app to be thrown away.
    Make sure your iTunes library has the latest updates for all your apps, then backup and restore the device. This should pull back a fresh copy of the app from your iTunes library and then give it the data from your device backup.
    tt2

  • Excel sheet for difference between EP 6.0 and EP 7.0

    Hi All,
    Wish all of you a very very Happy New Year 2008.
    Can some body send the excel sheet for difference between EP 6.0 and EP 7.0 to [email protected] asap.
    Thanks in advance
    Jyoti

    Aaaaggghhhh.
    Please could someone either get it uploaded as an article... or even easier, add it to the Portal Wiki.  It has an attachments tab!
    Then we won't have huge threads with e-mail addresses on (which bots will then pick up and send lots of spam to).
    Many Thanks
    Paul

  • Difference between SAP/APO/DP and the SAP/CRM solution for forecasting

    Hi,
    Can you please help me identifying the main differences between SAP/APO/DP and the SAP/CRM solution for forecasting? Advantages and disadvantages?
    Thanks a lot

    Hi LCD777,
    Forecasting at DP & CRM are altogether at different entities.  CRM involves webbased data transfer mechanism tool whereas DP is database/livecache driven tool.
    In CRM, you dont get optimised solution of forecasting out of it whereas in DP you can get as much as
    optimised solution & flexibility as per your requirements.
    DP is majorly a forecasting tool where in huge statistical method functionalities are embedded in
    whereas CRM is majorly a transactional tool wherein it involves gathering of forecast data and executing it.
    Typically, CRM will be integrated with DP containing GATP environment & ECC so that DP will plan for forecast data, ECC system drives sales order data & GATP calls for availability check and finally
    the forecast execution& transactions will be controlled by CRM
    Regards
    R. Senthil Mareeswaran.

  • I can't download the latest update 5.0.1 I've tried several times and it gets to the end of about 70 minutes of downloading and then says the server timed out. Had the ohone for a year and no trouble until now. Please advise what to do. Thanks.

    I can't download the latest update 5.0.1 I've tried several times and it gets to the end of about 70 minutes of downloading and then says the server timed out. Had the ohone for a year and no trouble until now. Please advise what to do. Thanks.

    DIsable your antivirus and firewall.

  • Difference between " COMPRESS FOR ALL OPERATIONS" and "COMPRESS FOR OLTP"?

    I was looking through Oracle's OLTP Table Compression (11g onwards) documentation as well as online resources to find the syntax and came across two different versions:
    COMPRESS FOR ALL OPERATIONS
    and
    COMPRESS FOR OLTP
    The documentation I looked through didn't mention any alternative syntax, so i was wondering if anyone here might know the difference.
    Thank you!

    Table Compression Enhancements in Oracle Database 11G Rel1 as as follows:
    The compression clause can be specified at the tablespace, table or partition level with the following options:
    •NOCOMPRESS - The table or partition is not compressed. This is the default action when no compression clause is specified.
    •COMPRESS - This option is considered suitable for data warehouse systems. Compression is enabled on the table or partition during direct-path inserts only.
    •COMPRESS FOR DIRECT_LOAD OPERATIONS - This option has the same affect as the simple COMPRESS keyword.
    •COMPRESS FOR ALL OPERATIONS - This option is considered suitable for OLTP systems. As the name implies, this option enables compression for all operations, including regular DML statements. This option requires the COMPATIBLE initialization parameter to be set to 11.1.0 or higher.

  • I have multiple apple devices mainly used between me and my wife , my question is that can i have two sets of contacts backed up to icloud one for her devices and one for my devices using the same itunes account

    i have two sets of devices one ipad, iphone and mac which i use and one iphone ipad and mac which my wife uses
    now is it possible to have two sets of contacts and calendar synchronised for her devices and one for my devices using the same icloud account
    i dont want a separate itunes account as we use the same music books and apps to be automatically downloaded which is very convenient
    please guide

    You can set up different iCloud accounts on each device using different Apple IDs (to keep your mail, calendars, contacts, etc. separated), and still share the same iTunes account (in Settings>Store on your device).  There is no requirement that you use the same Apple ID for purchases and for iCloud.

  • When my 6 year old daughter plays the free games that I have downloaded for her IPAD and IPOD, I am now getting upgrade charges on these free games to my AMEX Card. WHy is this happening and how do I get my AMEX card off of the IPAD and IPOD?

    When my 6 year old daughter plays the free games that I have downloaded for her IPAD and IPOD, I am now getting upgrade charges on these free games to my AMEX Card. Why is this happening and how do I get my AMEX card off of the IPAD and IPOD?

    She is making in app purchases. Probably not knowing what that means to your monthly credit card bill. Use the Settings app to enable restrictions and turn on restrictions for iTunes, App Store and in app purchases, mabe some others too. The restrictions will be set with a passcode to prevent your daughter from changing them.
    Settings > General > Restrictions

  • Well I have a new macbook pro and there is a software update available and after i update it, it keeps asking for the same thing to update over and over again! What can be done?

    Well I have a new macbook pro and there is a software update available and after i update it, it keeps asking for the same thing to update over and over again! What can be done?

    The App Store version sometimes gives problems. As you can't install 10.8.4 from the App Store, download and install the Combo edition > http://support.apple.com/kb/DL1659?viewlocale=en_US&locale=en_US This edition will work and will update OS X to the most recent version, in that case, 10.8.4

  • I've had my new iPhone 6 Plus for about a month now and I'm just now syncing it with my computer to put music on it and it has been on Step 5 of 5 for hours now.  I have reinstalled iTunes to see if that was the problem with no luck.

    I've had my new iPhone 6 Plus for about a month now and I'm just now syncing it with my computer to put music on it and it has been on Step 5 of 5 for hours now.  I have reinstalled iTunes to see if that was the problem with no luck.

    All it says is "waiting for changes to be applied".

Maybe you are looking for