Syntax\n------\n\nUUID()\n\nDescription\n-----------\n\nReturns a Universally Unique Identifier (UUID) version 1. Functions to generate v4 and v7 UUIDs are available from MariaDB 11.7. See UUIDv4 and UUIDv7 respectively.\n\nA UUID is designed as a number that is globally unique in space and time. Two calls to UUID() are expected to generate two different values, even if these calls are performed on two separate computers that are not connected to each other.\n\nUUID() results are intended to be unique, but cannot always be relied upon to be unpredictable and unguessable.\n\nA UUID is a 128-bit number represented by a utf8 string of five hexadecimal numbers in aaaaaaaa-bbbb-cccc-dddd-eeeeeeeeeeee format:\n\n The first three numbers are generated from a timestamp.\n The fourth number preserves temporal uniqueness in case the timestamp value\\\n  loses monotonicity (for example, due to daylight saving time).\n* The fifth number is an IEEE 802 node number that provides spatial uniqueness.\\\n  A random number is substituted if the latter is not available (for example,\\\n  because the host computer has no Ethernet card, or we do not know how to find\\\n  the hardware address of an interface on your operating system). In this case,\\\n  spatial uniqueness cannot be guaranteed. Nevertheless, a collision should\\\n  have very low probability.\n\nCurrently, the MAC address of an interface is taken into account only on FreeBSD and Linux. On other operating systems, MariaDB uses a randomly generated 48-bit number.\n\nStatements using the UUID() function are not safe for statement-based replication.\n\nThe function generates a UUIDv1 and the results are generated according to the "DCE 1.1:Remote Procedure Call" (Appendix A) CAE (Common Applications Environment) Specifications published by The Open Group in October 1997 (Document Number C706).\n\nExamples\n--------\n\nSELECT UUID();\n+--------------------------------------+\n| UUID()                               |\n+--------------------------------------+\n| cd41294a-afb0-11df-bc9b-00241dd75637 |\n+--------------------------------------+\n\nURL: https://mariadb.com/docs/server/reference/sql-functions/secondary-functions/miscellaneous-functions/uuid