DBAsupport.com Forums - Powered by vBulletin
Results 1 to 10 of 10

Thread: What's the command to find out patch version?

  1. #1
    Join Date
    Oct 2000
    Posts
    76
    How do I find out if a patch has been applied, and if so, the version of the patch?
    J.T.

  2. #2
    Join Date
    Nov 2000
    Location
    Pittsburgh, PA
    Posts
    4,166
    You can try this in 8i:

    FUNCTION DbReleaseNumber RETURN VARCHAR2 IS
    VersionNumber VARCHAR2(20);
    Compatibility VARCHAR2(20);
    BEGIN
    DBMS_UTILITY.Db_Version( VersionNumber, Compatibility);
    RETURN VersionNumber;
    EXCEPTION
    WHEN OTHERS THEN
    return(NULL);
    END;

  3. #3
    Join Date
    Dec 2000
    Location
    Ljubljana, Slovenia
    Posts
    4,439
    Note that not all patches leave their "footprint" in the versionnumber. For example, if you apply patch 8.1.7.1.2 to your database (after you have applied 8.1.7.1.1), you will still see 8.1.7.1.1 as your release everywhere.
    Jurij Modic
    ASCII a stupid question, get a stupid ANSI
    24 hours in a day .... 24 beer in a case .... coincidence?

  4. #4
    Join Date
    Oct 2000
    Posts
    76
    So if you reapply the same patch again unknowingly, would that be a problem?
    J.T.

  5. #5
    Join Date
    Oct 2000
    Location
    Saskatoon, SK, Canada
    Posts
    3,925
    To get this information you can check the oraInventory/Patches this would reveal you the patches that you have applied so far on to the database.

    Sam
    Thanx
    Sam



    Life is a journey, not a destination!


  6. #6
    Join Date
    Dec 2000
    Location
    Ljubljana, Slovenia
    Posts
    4,439
    Originally posted by sambavan
    To get this information you can check the oraInventory/Patches this would reveal you the patches that you have applied so far on to the database.
    I stress again: this is true only if the pach has been applied through Universal Installer.

    But some "minor" patches can not be applied like this - for them to be "installed" you simply has to copy bunch of exec and library files over the old ones. To keep track of such paches installed there is no other way than to have a good memory or good "document everything" habit.

    And to answer jt: I don't think there would be a problem to reapply same patch again, unless it is lower than the highest patch allready applied. If the patch has to be installed by Oracle Universal Installer then the Installer will complain anyway.
    Jurij Modic
    ASCII a stupid question, get a stupid ANSI
    24 hours in a day .... 24 beer in a case .... coincidence?

  7. #7
    Join Date
    Oct 2002
    Posts
    391
    okay.. so there is no way to see which patch has been applied since there are other workarounds.....

    for example, all_dba_links will show u all the dba_links. i was wondering whether there are similar ones for patches?

    opatcah isinventory will work for oracle 8.1.7.4

    Thanks
    Last edited by yls177; 07-22-2005 at 04:40 AM.

  8. #8
    Join Date
    Dec 2001
    Location
    UK
    Posts
    1,684
    Is this available in 8i?

    select comp_name, version, status from dba_registry;

    Can't test at the moment, but it works in 9i and 10g for patches that update the data

    Cheers

    Tim...
    Last edited by TimHall; 07-22-2005 at 08:32 AM.
    Tim...
    OCP DBA 7.3, 8, 8i, 9i, 10g, 11g
    OCA PL/SQL Developer
    Oracle ACE Director
    My website: oracle-base.com
    My blog: oracle-base.com/blog

  9. #9
    Join Date
    Nov 2002
    Location
    New Delhi, INDIA
    Posts
    1,796
    Quote Originally Posted by TimHall
    Is this available in 8i?

    select comp_name, version, status from dba_registry;

    Can't test at the moment, but it works in 9i and 10g for patches that update the data

    Cheers

    Tim...
    AFAIK it's there from 9i onwards.
    Amar
    "There is a difference between knowing the path and walking the path."

    Amar's Blog  Get Firefox!

  10. #10
    Join Date
    Dec 2001
    Location
    UK
    Posts
    1,684
    Quote Originally Posted by adewri
    AFAIK it's there from 9i onwards.
    I thought you were insulting me for a minute, then I looked up AFAIK on google and all was revealed

    Cheers

    Tim...
    Tim...
    OCP DBA 7.3, 8, 8i, 9i, 10g, 11g
    OCA PL/SQL Developer
    Oracle ACE Director
    My website: oracle-base.com
    My blog: oracle-base.com/blog

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  


Click Here to Expand Forum to Full Width