/* Used By This Project */
SELECT DECODE( ev.PKG_STATE, NULL, 0, ev.PKG_STATE ) AS PKG_STATE,
	   rt.RTAG_ID,
	   rt.RTAG_NAME,
	   rt.OFFICIAL,
	   ev.ENV_AREA,
	   pv.PV_ID,
	   pkg.PKG_NAME,
	   pv.PKG_VERSION,
	   pv.DLOCKED,
	   usr.FULL_NAME,
	   usr.USER_EMAIL,
	   pv.MODIFIED_STAMP  
  FROM ENVIRONMENT_VIEW ev,
  	   PACKAGE_VERSIONS pv,
	   PACKAGES pkg,
	   RELEASE_TAGS rt,
	   USERS usr
 WHERE ev.PV_ID = pv.PV_ID
   AND pv.PKG_ID = :PKG_ID
   AND NVL( pv.V_EXT, '|LINK_A_NULL|') = NVL( :V_EXT, '|LINK_A_NULL|')
   AND pv.PKG_ID = pkg.PKG_ID
   AND ev.RTAG_ID = rt.RTAG_ID
   AND pv.MODIFIER_ID = usr.USER_ID
   AND rt.PROJ_ID = :PROJ_ID
 ORDER BY rt.RTAG_ID DESC 