Is there any way to insert a UUID
automatically into a table field, just as it does with a field of type AUTO_INCREMENT
?
VARCHAR(40)
, it inserts a UUID
automatically, as if it were the auto increment of the table.
Is there a way to do this directly through MySQL? Or do we always have to set the UUID at the time of INSERT
?
Example:
Usuarios
- uuid
- nome
- senha