Available in versions: Dev (3.20)

This documentation is for the unreleased development version of jOOQ. Click on the above version links to get this documentation for a supported version of jOOQ.

UUID_TO_BIN

Applies to ✅ Open Source Edition   ✅ Express Edition   ✅ Professional Edition   ✅ Enterprise Edition

The UUID_TO_BIN() function converts a VARCHAR or UUID representation into a BINARY(16) representation. See also BIN_TO_UUID for the inverse function.

SELECT uuid_to_bin(
  '1fc454e5-b9f6-4d55-b783-5987fe76cb45'
);
create.select(uuidToBin(
  UUID.fromString("1fc454e5-b9f6-4d55-b783-5987fe76cb45")
)).fetch();

The result being

+------------------+
| uuid_to_bin      |
+------------------+
|  ÄTå¹öMU· Y þvËE |
+------------------+
uuidToBin(java.util.UUID.fromString("1fc454e5-b9f6-4d55-b783-5987fe76cb45"))

References to this page

Feedback

Do you have any feedback about this page? We'd love to hear it!

The jOOQ Logo