Code: Select all
--SELECT SUBSTR( (SELECT REGEXP_REPLACE(SYS_GUID(), '(.{8})(.{4})(.{4})(.{4})(.{12})', '\1-\2-\3-\4-\5') MSSQL_GUID FROM DUAL), 1,15) FROM DUAL
SELECT SUBSTR( (SELECT REGEXP_REPLACE(SYS_GUID(), '(.{8})(.{4})(.{4})(.{4})', '\4') MSSQL_GUID FROM DUAL), 5,20) FROM DUAL
SELECT SUBSTR( (
SELECT REGEXP_REPLACE(SYS_GUID(), '(.{8})(.{4})(.{4})(.{4})(.{12})', '\1-\2-\3-\4-\5') MSSQL_GUID FROM DUAL
), 1,15) FROM DUAL
SELECT CAST (SYS_GUID() AS VARCHAR(32)) FROM DUAL