/* Make Bulk Patches Official */ 
 
  
		 SELECT pp.PATCH_ID AS PPATCH_ID,
		 		0 AS PATCH_ID,
		        pp.INSTALL_ORDER,
                pkg.PKG_NAME,
                pv.PKG_VERSION,
                pv.COMMENTS,
                pv.OBSOLETE_COMMENTS,
                pv.DLOCKED, 
                pv.IS_PATCH,
                pv.is_obsolete,
                usr.FULL_NAME,
                usr.USER_EMAIL
		   FROM PACKAGE_PATCHES pp,
           	    PACKAGES pkg,
                PACKAGE_VERSIONS pv,
                USERS usr
		  WHERE pp.PV_ID = :PV_ID
            AND pv.PKG_ID = pkg.PKG_ID
            AND pp.PATCH_ID = pv.PV_ID
            AND pv.MODIFIER_ID = usr.USER_ID
			AND dlocked = 'N'
			AND pv.is_obsolete IS NULL
			AND pv.comments IS NOT NULL
			
 ORDER BY INSTALL_ORDER, PATCH_ID         
