Friday, August 29, 2014

Pre-defined Collection table in Oracle

select owner, type_name, coll_type, elem_type_name, length from dba_coll_types
where TYPE_NAME IN ('DBMS_DEBUG_VC2COLL', 'KU$_VCNT');


SELECT COLUMN_VALUE FROM TABLE(SYS.DBMS_DEBUG_VC2COLL('123', 'ABCD', 'LMN'));


SELECT COLUMN_VALUE FROM TABLE(SYS.KU$_VCNT('123', 'ABCD', 'LMN'));

Original post:
http://awads.net/wp/2005/10/13/pre-defined-collection-types-in-oracle

36 Character GUID generation in Oracle using SYS_GUID

SELECT REGEXP_REPLACE(sys_guid(), '(........)(....)(....)(....)(............)','\1-\2-\3-\4-\5') FROM DUAL;