Check PSU Applied using dbms_qopatch

New in Oracle 12c

Reference:

https://www.pythian.com/blog/oracle-database-12c-patching-dbms_qopatch-opatch_xml_inv-and-datapatch/
https://blogs.oracle.com/UPGRADE/entry/dbms_qopatch_datapatch_and_other
http://docs.oracle.com/database/121/ARPLS/d_qopatch.htm#ARPLS74834

-- Checking PSU Applied using dbms_qopatch

exec dbms_qopatch.get_sqlpatch_status;

Patch Id : 23054246
        Action : APPLY
        Action Time : 17-NOV-2016 16:57:34
        Description : Database Patch Set Update : 12.1.0.2.160719 (23054246)
        Logfile : /u01/app/oracle/cfgtoollogs/sqlpatch/23054246/20464632/23054246_apply_DB01_2016Nov17_16_57_29.log
        Status : SUCCESS

PL/SQL procedure successfully completed.


--- Home and Inventory

set pagesize 0
set long 1000000

select xmltransform(dbms_qopatch.get_opatch_install_info, 
dbms_qopatch.get_opatch_xslt) "Home and Inventory" from dual;

Oracle Home       : /u01/oracle/products/12.1.0/dbhome_1
Inventory         : /u01/oraInventory


1 row selected.
--- Specific Patch

select xmltransform(dbms_qopatch.is_patch_installed('21359755'), 
dbms_qopatch.get_opatch_xslt) "Patch installed?" from dual;

Patch Information:
         21359755:   applied on 2016-10-26T11:18:57+02:00


1 row selected.

--- All Details:

select xmltransform(dbms_qopatch.get_opatch_lsinventory, 
dbms_qopatch.get_opatch_xslt) from dual;

Oracle Querayable Patch Interface 1.0
--------------------------------------------------------------------------------
Oracle Home       : /u01/oracle/products/12.1.0/dbhome_1
Inventory         : /u01/oraInventory
--------------------------------------------------------------------------------
Installed Top-level Products (1):
                                    12.1.0.2.0
Installed Products ( 135)

                                                            12.1.0.2.0
                                                            1.6.0.75.0
                                                            12.1.0.2.0
                                                            12.1.0.2.0
                                                            12.1.0.1.2
                                                            12.1.0.2.0
...

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s