Thursday, March 4, 2010

Online GUID Generator's

http://www.guidgenerator.com/online-guid-generator.aspx
http://www.somacon.com/p113.php
http://www.hoskinson.net/GuidGenerator/default.asp
http://www.fileformat.info/tool/guid.htm
https://developer.mozilla.org/en/Generating_GUIDs

Oracle's GUID

SYS_GUID generates and returns a globally unique identifier (RAW value) made up of 16 bytes. On most platforms, the generated identifier consists of a host identifier, a process or thread identifier of the process or thread invoking the function, and a nonrepeating value (sequence of bytes) for that process or thread.

Examples

The following example adds a column to the sample table hr.locations, inserts unique identifiers into each row, and returns the 32-character hexadecimal representation of the 16-byte RAW value of the global unique identifier:

Example 1:

ALTER TABLE locations ADD (uid_col RAW(16));

UPDATE locations SET uid_col = SYS_GUID();

SELECT location_id, uid_col FROM locations
ORDER BY location_id, uid_col;

LOCATION_ID UID_COL
----------- ----------------------------------------------------------------
1000 09F686761827CF8AE040578CB20B7491
1100 09F686761828CF8AE040578CB20B7491
1200 09F686761829CF8AE040578CB20B7491
1300 09F68676182ACF8AE040578CB20B7491
1400 09F68676182BCF8AE040578CB20B7491
1500 09F68676182CCF8AE040578CB20B7491

Example 2:

create table test (ID raw(16) default sys_guid(), name varchar2(10));

insert into test(name) values ('DAS');

insert into test(name) values ('DDAS');

select * from test;

ID NAME
-------------------------------- ----------
CF874CB4F32A47C19859DA2BB0D71AB4 DAS
2B768E600A484391B6B8D5C4924D2785 DDAS

No comments: