Bug #72899 Feature request - UUID/uniqueidentifier data type
Submitted: 6 Jun 2014 14:45
Reporter: Denis Kras Email Updates:
Status: Open Impact on me:
None 
Category:MySQL Server: Data Types Severity:S4 (Feature request)
Version:any OS:Any
Assigned to: CPU Architecture:Any
Tags: Data Type, Guid, uniqueidentifier, UUID

[6 Jun 2014 14:45] Denis Kras
Description:
It would be great if you could add UUID/uniqueidentifier data type to MySql. Almost all major competitors like SQL Server, PostgreSQL and others already have this data type.

Right now, the only alternative is to use either char(36) or binary(16) types. However, both of them has notable disadvantages (performance, formatting etc...) Having a native data type will fix all those issues.

How to repeat:
The following statement will not work:

CREATE TABLE mytable (
  Id UUID NOT NULL,
  CONSTRAINT mytable_Id PRIMARY KEY CLUSTERED (Id)
);

Suggested fix:
Add a new data type for storing UUID values. Internally it may be stored as binary(16).