I have an Oracle project that would be a good fit for using GUIDs as a key. I found the following snippet
SET SERVEROUTPUT ON
BEGIN
FOR indx IN 1 .. 5
LOOP
DBMS_OUTPUT.put_line ( SYS_GUID );
END LOOP;
END;
/
From http://feuerthoughts.blogspot.com/2006/02/watch-out-for-sequential-oracle-guids.html
When I run it against my database (I tried it on versions 10g and version 11) I get output like
64FE4083D6BA7CB4E0400F0A0E0A18B0
64FE4083D6BB7CB4E0400F0A0E0A18B0
64FE4083D6BC7CB4E0400F0A0E0A18B0
64FE4083D6BD7CB4E0400F0A0E0A18B0
64FE4083D6BE7CB4E0400F0A0E0A18B0
I.e. the value never changes! Is there something I have to do to set this up to work as expected?
Edit: I am not very observant - the GUIDs are changing, but it looks like I am suffering from the sequential GUID problem that the link above is talking about.