Bug #89474 | UUID() used in string functions not unique if charset is 'utf8mb4' | ||
---|---|---|---|
Submitted: | 30 Jan 2018 16:59 | Modified: | 6 Oct 2020 12:54 |
Reporter: | EGOR Upatov | Email Updates: | |
Status: | Not a Bug | Impact on me: | |
Category: | MySQL Server: Charsets | Severity: | S4 (Feature request) |
Version: | 5.6+ | OS: | Any |
Assigned to: | CPU Architecture: | Any | |
Tags: | utf8mb4, UUID |
[30 Jan 2018 16:59]
EGOR Upatov
[6 Oct 2020 12:54]
MySQL Verification Team
Hi Mr. Upatov, Thank you for your feature request. However, I have tried latest releases of both 5.7 and 8.0 and all is just fine: SELECT UUID() AS unique_column, REPLACE(UUID(), '-', '') AS non_unique_column FROM a; +--------------------------------------+----------------------------------+ | unique_column | non_unique_column | +--------------------------------------+----------------------------------+ | c23dda18-07d2-11eb-bafd-0226b725957a | c23ddaa407d211ebbafd0226b725957a | | c23ddc02-07d2-11eb-bafd-0226b725957a | c23ddc1607d211ebbafd0226b725957a | +--------------------------------------+----------------------------------+ 2 rows in set (0.00 sec) mysql> set names 'utf8'; Query OK, 0 rows affected, 1 warning (0.00 sec) mysql> SELECT UUID() AS unique_column, REPLACE(UUID(), '-', '') AS non_unique_column FROM a; +--------------------------------------+----------------------------------+ | unique_column | non_unique_column | +--------------------------------------+----------------------------------+ | ce6ce41e-07d2-11eb-bafd-0226b725957a | ce6ce43207d211ebbafd0226b725957a | | ce6ce5d6-07d2-11eb-bafd-0226b725957a | ce6ce5e007d211ebbafd0226b725957a | +--------------------------------------+----------------------------------+ Not a bug !!!!