Skip to content

Instantly share code, notes, and snippets.

@jclement
Created March 28, 2016 15:28
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jclement/2fab033d036f55376bac to your computer and use it in GitHub Desktop.
Save jclement/2fab033d036f55376bac to your computer and use it in GitHub Desktop.
Generate a GUID in form "1ce9b033-d9fa-452a-8767-970fb0548eb4" from Oracle
select lower(regexp_replace(rawtohex(sys_guid()), '([A-F0-9]{8})([A-F0-9]{4})([A-F0-9]{4})([A-F0-9]{4})([A-F0-9]{12})', '\1-\2-\3-\4-\5')) from dual
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment