diff options
author | Alexander Barkov <bar@mariadb.com> | 2021-10-19 13:17:11 +0400 |
---|---|---|
committer | Sergei Golubchik <serg@mariadb.org> | 2021-10-29 18:29:02 +0200 |
commit | b9f19f7eae960b6ebf769a3d0c63045ed5f2ce6c (patch) | |
tree | a75713f72ebdb5d6d00fd75c024d8178ab5e9120 /plugin/type_uuid/mysql-test/type_uuid/type_uuid.result | |
parent | 50bcda010f1d9f389ce41b331b355fdb5b5d587c (diff) | |
download | mariadb-git-b9f19f7eae960b6ebf769a3d0c63045ed5f2ce6c.tar.gz |
MDEV-26664 Store UUIDs in a more efficient manner
UUID values
llllllll-mmmm-Vhhh-vsss-nnnnnnnnnnnn
are now stored as
nnnnnnnnnnnn-vsss-Vhhh-mmmm-llllllll
inside the record:
- the groups (segments separated by dash) are reordered right-to-left.
- the bytes inside the groups are not reordered (stored as before,
in big-endian format).
This provides a better sorting order: the earlier UUID was generated,
the higher it appears in the ORDER BY output.
Also, this change enables a good key prefix compression,
because the constant part is now in the beginning, while
the non-constant part (the timestamp) is in the end.
Diffstat (limited to 'plugin/type_uuid/mysql-test/type_uuid/type_uuid.result')
-rw-r--r-- | plugin/type_uuid/mysql-test/type_uuid/type_uuid.result | 1067 |
1 files changed, 1065 insertions, 2 deletions
diff --git a/plugin/type_uuid/mysql-test/type_uuid/type_uuid.result b/plugin/type_uuid/mysql-test/type_uuid/type_uuid.result index 6a08ffe8c23..615222651a5 100644 --- a/plugin/type_uuid/mysql-test/type_uuid/type_uuid.result +++ b/plugin/type_uuid/mysql-test/type_uuid/type_uuid.result @@ -369,6 +369,1069 @@ SELECT * FROM t1 WHERE a IN ('::', 10); ERROR HY000: Illegal parameter data types uuid and int for operation 'in' DROP TABLE t1; # +# ORDER BY +# +CREATE TABLE t1 (a UUID); +FOR i IN 0..15 +DO +INSERT INTO t1 VALUES (REPLACE('XX000000-0000-0000-0000-000000000000','XX',LPAD(HEX(i),2,'0'))); +INSERT INTO t1 VALUES (REPLACE('00XX0000-0000-0000-0000-000000000000','XX',LPAD(HEX(i),2,'0'))); +INSERT INTO t1 VALUES (REPLACE('0000XX00-0000-0000-0000-000000000000','XX',LPAD(HEX(i),2,'0'))); +INSERT INTO t1 VALUES (REPLACE('000000XX-0000-0000-0000-000000000000','XX',LPAD(HEX(i),2,'0'))); +INSERT INTO t1 VALUES (REPLACE('00000000-XX00-0000-0000-000000000000','XX',LPAD(HEX(i),2,'0'))); +INSERT INTO t1 VALUES (REPLACE('00000000-00XX-0000-0000-000000000000','XX',LPAD(HEX(i),2,'0'))); +INSERT INTO t1 VALUES (REPLACE('00000000-0000-XX00-0000-000000000000','XX',LPAD(HEX(i),2,'0'))); +INSERT INTO t1 VALUES (REPLACE('00000000-0000-00XX-0000-000000000000','XX',LPAD(HEX(i),2,'0'))); +INSERT INTO t1 VALUES (REPLACE('00000000-0000-0000-XX00-000000000000','XX',LPAD(HEX(i),2,'0'))); +INSERT INTO t1 VALUES (REPLACE('00000000-0000-0000-00XX-000000000000','XX',LPAD(HEX(i),2,'0'))); +INSERT INTO t1 VALUES (REPLACE('00000000-0000-0000-0000-XX0000000000','XX',LPAD(HEX(i),2,'0'))); +INSERT INTO t1 VALUES (REPLACE('00000000-0000-0000-0000-00XX00000000','XX',LPAD(HEX(i),2,'0'))); +INSERT INTO t1 VALUES (REPLACE('00000000-0000-0000-0000-0000XX000000','XX',LPAD(HEX(i),2,'0'))); +INSERT INTO t1 VALUES (REPLACE('00000000-0000-0000-0000-000000XX0000','XX',LPAD(HEX(i),2,'0'))); +INSERT INTO t1 VALUES (REPLACE('00000000-0000-0000-0000-00000000XX00','XX',LPAD(HEX(i),2,'0'))); +INSERT INTO t1 VALUES (REPLACE('00000000-0000-0000-0000-0000000000XX','XX',LPAD(HEX(i),2,'0'))); +END FOR; +$$ +# +# Logical ORDER BY +# +SELECT * FROM t1 ORDER BY a; +a +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000000 +00000001-0000-0000-0000-000000000000 +00000002-0000-0000-0000-000000000000 +00000003-0000-0000-0000-000000000000 +00000004-0000-0000-0000-000000000000 +00000005-0000-0000-0000-000000000000 +00000006-0000-0000-0000-000000000000 +00000007-0000-0000-0000-000000000000 +00000008-0000-0000-0000-000000000000 +00000009-0000-0000-0000-000000000000 +0000000a-0000-0000-0000-000000000000 +0000000b-0000-0000-0000-000000000000 +0000000c-0000-0000-0000-000000000000 +0000000d-0000-0000-0000-000000000000 +0000000e-0000-0000-0000-000000000000 +0000000f-0000-0000-0000-000000000000 +00000100-0000-0000-0000-000000000000 +00000200-0000-0000-0000-000000000000 +00000300-0000-0000-0000-000000000000 +00000400-0000-0000-0000-000000000000 +00000500-0000-0000-0000-000000000000 +00000600-0000-0000-0000-000000000000 +00000700-0000-0000-0000-000000000000 +00000800-0000-0000-0000-000000000000 +00000900-0000-0000-0000-000000000000 +00000a00-0000-0000-0000-000000000000 +00000b00-0000-0000-0000-000000000000 +00000c00-0000-0000-0000-000000000000 +00000d00-0000-0000-0000-000000000000 +00000e00-0000-0000-0000-000000000000 +00000f00-0000-0000-0000-000000000000 +00010000-0000-0000-0000-000000000000 +00020000-0000-0000-0000-000000000000 +00030000-0000-0000-0000-000000000000 +00040000-0000-0000-0000-000000000000 +00050000-0000-0000-0000-000000000000 +00060000-0000-0000-0000-000000000000 +00070000-0000-0000-0000-000000000000 +00080000-0000-0000-0000-000000000000 +00090000-0000-0000-0000-000000000000 +000a0000-0000-0000-0000-000000000000 +000b0000-0000-0000-0000-000000000000 +000c0000-0000-0000-0000-000000000000 +000d0000-0000-0000-0000-000000000000 +000e0000-0000-0000-0000-000000000000 +000f0000-0000-0000-0000-000000000000 +01000000-0000-0000-0000-000000000000 +02000000-0000-0000-0000-000000000000 +03000000-0000-0000-0000-000000000000 +04000000-0000-0000-0000-000000000000 +05000000-0000-0000-0000-000000000000 +06000000-0000-0000-0000-000000000000 +07000000-0000-0000-0000-000000000000 +08000000-0000-0000-0000-000000000000 +09000000-0000-0000-0000-000000000000 +0a000000-0000-0000-0000-000000000000 +0b000000-0000-0000-0000-000000000000 +0c000000-0000-0000-0000-000000000000 +0d000000-0000-0000-0000-000000000000 +0e000000-0000-0000-0000-000000000000 +0f000000-0000-0000-0000-000000000000 +00000000-0001-0000-0000-000000000000 +00000000-0002-0000-0000-000000000000 +00000000-0003-0000-0000-000000000000 +00000000-0004-0000-0000-000000000000 +00000000-0005-0000-0000-000000000000 +00000000-0006-0000-0000-000000000000 +00000000-0007-0000-0000-000000000000 +00000000-0008-0000-0000-000000000000 +00000000-0009-0000-0000-000000000000 +00000000-000a-0000-0000-000000000000 +00000000-000b-0000-0000-000000000000 +00000000-000c-0000-0000-000000000000 +00000000-000d-0000-0000-000000000000 +00000000-000e-0000-0000-000000000000 +00000000-000f-0000-0000-000000000000 +00000000-0100-0000-0000-000000000000 +00000000-0200-0000-0000-000000000000 +00000000-0300-0000-0000-000000000000 +00000000-0400-0000-0000-000000000000 +00000000-0500-0000-0000-000000000000 +00000000-0600-0000-0000-000000000000 +00000000-0700-0000-0000-000000000000 +00000000-0800-0000-0000-000000000000 +00000000-0900-0000-0000-000000000000 +00000000-0a00-0000-0000-000000000000 +00000000-0b00-0000-0000-000000000000 +00000000-0c00-0000-0000-000000000000 +00000000-0d00-0000-0000-000000000000 +00000000-0e00-0000-0000-000000000000 +00000000-0f00-0000-0000-000000000000 +00000000-0000-0001-0000-000000000000 +00000000-0000-0002-0000-000000000000 +00000000-0000-0003-0000-000000000000 +00000000-0000-0004-0000-000000000000 +00000000-0000-0005-0000-000000000000 +00000000-0000-0006-0000-000000000000 +00000000-0000-0007-0000-000000000000 +00000000-0000-0008-0000-000000000000 +00000000-0000-0009-0000-000000000000 +00000000-0000-000a-0000-000000000000 +00000000-0000-000b-0000-000000000000 +00000000-0000-000c-0000-000000000000 +00000000-0000-000d-0000-000000000000 +00000000-0000-000e-0000-000000000000 +00000000-0000-000f-0000-000000000000 +00000000-0000-0100-0000-000000000000 +00000000-0000-0200-0000-000000000000 +00000000-0000-0300-0000-000000000000 +00000000-0000-0400-0000-000000000000 +00000000-0000-0500-0000-000000000000 +00000000-0000-0600-0000-000000000000 +00000000-0000-0700-0000-000000000000 +00000000-0000-0800-0000-000000000000 +00000000-0000-0900-0000-000000000000 +00000000-0000-0a00-0000-000000000000 +00000000-0000-0b00-0000-000000000000 +00000000-0000-0c00-0000-000000000000 +00000000-0000-0d00-0000-000000000000 +00000000-0000-0e00-0000-000000000000 +00000000-0000-0f00-0000-000000000000 +00000000-0000-0000-0001-000000000000 +00000000-0000-0000-0002-000000000000 +00000000-0000-0000-0003-000000000000 +00000000-0000-0000-0004-000000000000 +00000000-0000-0000-0005-000000000000 +00000000-0000-0000-0006-000000000000 +00000000-0000-0000-0007-000000000000 +00000000-0000-0000-0008-000000000000 +00000000-0000-0000-0009-000000000000 +00000000-0000-0000-000a-000000000000 +00000000-0000-0000-000b-000000000000 +00000000-0000-0000-000c-000000000000 +00000000-0000-0000-000d-000000000000 +00000000-0000-0000-000e-000000000000 +00000000-0000-0000-000f-000000000000 +00000000-0000-0000-0100-000000000000 +00000000-0000-0000-0200-000000000000 +00000000-0000-0000-0300-000000000000 +00000000-0000-0000-0400-000000000000 +00000000-0000-0000-0500-000000000000 +00000000-0000-0000-0600-000000000000 +00000000-0000-0000-0700-000000000000 +00000000-0000-0000-0800-000000000000 +00000000-0000-0000-0900-000000000000 +00000000-0000-0000-0a00-000000000000 +00000000-0000-0000-0b00-000000000000 +00000000-0000-0000-0c00-000000000000 +00000000-0000-0000-0d00-000000000000 +00000000-0000-0000-0e00-000000000000 +00000000-0000-0000-0f00-000000000000 +00000000-0000-0000-0000-000000000001 +00000000-0000-0000-0000-000000000002 +00000000-0000-0000-0000-000000000003 +00000000-0000-0000-0000-000000000004 +00000000-0000-0000-0000-000000000005 +00000000-0000-0000-0000-000000000006 +00000000-0000-0000-0000-000000000007 +00000000-0000-0000-0000-000000000008 +00000000-0000-0000-0000-000000000009 +00000000-0000-0000-0000-00000000000a +00000000-0000-0000-0000-00000000000b +00000000-0000-0000-0000-00000000000c +00000000-0000-0000-0000-00000000000d +00000000-0000-0000-0000-00000000000e +00000000-0000-0000-0000-00000000000f +00000000-0000-0000-0000-000000000100 +00000000-0000-0000-0000-000000000200 +00000000-0000-0000-0000-000000000300 +00000000-0000-0000-0000-000000000400 +00000000-0000-0000-0000-000000000500 +00000000-0000-0000-0000-000000000600 +00000000-0000-0000-0000-000000000700 +00000000-0000-0000-0000-000000000800 +00000000-0000-0000-0000-000000000900 +00000000-0000-0000-0000-000000000a00 +00000000-0000-0000-0000-000000000b00 +00000000-0000-0000-0000-000000000c00 +00000000-0000-0000-0000-000000000d00 +00000000-0000-0000-0000-000000000e00 +00000000-0000-0000-0000-000000000f00 +00000000-0000-0000-0000-000000010000 +00000000-0000-0000-0000-000000020000 +00000000-0000-0000-0000-000000030000 +00000000-0000-0000-0000-000000040000 +00000000-0000-0000-0000-000000050000 +00000000-0000-0000-0000-000000060000 +00000000-0000-0000-0000-000000070000 +00000000-0000-0000-0000-000000080000 +00000000-0000-0000-0000-000000090000 +00000000-0000-0000-0000-0000000a0000 +00000000-0000-0000-0000-0000000b0000 +00000000-0000-0000-0000-0000000c0000 +00000000-0000-0000-0000-0000000d0000 +00000000-0000-0000-0000-0000000e0000 +00000000-0000-0000-0000-0000000f0000 +00000000-0000-0000-0000-000001000000 +00000000-0000-0000-0000-000002000000 +00000000-0000-0000-0000-000003000000 +00000000-0000-0000-0000-000004000000 +00000000-0000-0000-0000-000005000000 +00000000-0000-0000-0000-000006000000 +00000000-0000-0000-0000-000007000000 +00000000-0000-0000-0000-000008000000 +00000000-0000-0000-0000-000009000000 +00000000-0000-0000-0000-00000a000000 +00000000-0000-0000-0000-00000b000000 +00000000-0000-0000-0000-00000c000000 +00000000-0000-0000-0000-00000d000000 +00000000-0000-0000-0000-00000e000000 +00000000-0000-0000-0000-00000f000000 +00000000-0000-0000-0000-000100000000 +00000000-0000-0000-0000-000200000000 +00000000-0000-0000-0000-000300000000 +00000000-0000-0000-0000-000400000000 +00000000-0000-0000-0000-000500000000 +00000000-0000-0000-0000-000600000000 +00000000-0000-0000-0000-000700000000 +00000000-0000-0000-0000-000800000000 +00000000-0000-0000-0000-000900000000 +00000000-0000-0000-0000-000a00000000 +00000000-0000-0000-0000-000b00000000 +00000000-0000-0000-0000-000c00000000 +00000000-0000-0000-0000-000d00000000 +00000000-0000-0000-0000-000e00000000 +00000000-0000-0000-0000-000f00000000 +00000000-0000-0000-0000-010000000000 +00000000-0000-0000-0000-020000000000 +00000000-0000-0000-0000-030000000000 +00000000-0000-0000-0000-040000000000 +00000000-0000-0000-0000-050000000000 +00000000-0000-0000-0000-060000000000 +00000000-0000-0000-0000-070000000000 +00000000-0000-0000-0000-080000000000 +00000000-0000-0000-0000-090000000000 +00000000-0000-0000-0000-0a0000000000 +00000000-0000-0000-0000-0b0000000000 +00000000-0000-0000-0000-0c0000000000 +00000000-0000-0000-0000-0d0000000000 +00000000-0000-0000-0000-0e0000000000 +00000000-0000-0000-0000-0f0000000000 +SELECT COALESCE(NULL, a) FROM t1 ORDER BY a; +COALESCE(NULL, a) +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000000 +00000001-0000-0000-0000-000000000000 +00000002-0000-0000-0000-000000000000 +00000003-0000-0000-0000-000000000000 +00000004-0000-0000-0000-000000000000 +00000005-0000-0000-0000-000000000000 +00000006-0000-0000-0000-000000000000 +00000007-0000-0000-0000-000000000000 +00000008-0000-0000-0000-000000000000 +00000009-0000-0000-0000-000000000000 +0000000a-0000-0000-0000-000000000000 +0000000b-0000-0000-0000-000000000000 +0000000c-0000-0000-0000-000000000000 +0000000d-0000-0000-0000-000000000000 +0000000e-0000-0000-0000-000000000000 +0000000f-0000-0000-0000-000000000000 +00000100-0000-0000-0000-000000000000 +00000200-0000-0000-0000-000000000000 +00000300-0000-0000-0000-000000000000 +00000400-0000-0000-0000-000000000000 +00000500-0000-0000-0000-000000000000 +00000600-0000-0000-0000-000000000000 +00000700-0000-0000-0000-000000000000 +00000800-0000-0000-0000-000000000000 +00000900-0000-0000-0000-000000000000 +00000a00-0000-0000-0000-000000000000 +00000b00-0000-0000-0000-000000000000 +00000c00-0000-0000-0000-000000000000 +00000d00-0000-0000-0000-000000000000 +00000e00-0000-0000-0000-000000000000 +00000f00-0000-0000-0000-000000000000 +00010000-0000-0000-0000-000000000000 +00020000-0000-0000-0000-000000000000 +00030000-0000-0000-0000-000000000000 +00040000-0000-0000-0000-000000000000 +00050000-0000-0000-0000-000000000000 +00060000-0000-0000-0000-000000000000 +00070000-0000-0000-0000-000000000000 +00080000-0000-0000-0000-000000000000 +00090000-0000-0000-0000-000000000000 +000a0000-0000-0000-0000-000000000000 +000b0000-0000-0000-0000-000000000000 +000c0000-0000-0000-0000-000000000000 +000d0000-0000-0000-0000-000000000000 +000e0000-0000-0000-0000-000000000000 +000f0000-0000-0000-0000-000000000000 +01000000-0000-0000-0000-000000000000 +02000000-0000-0000-0000-000000000000 +03000000-0000-0000-0000-000000000000 +04000000-0000-0000-0000-000000000000 +05000000-0000-0000-0000-000000000000 +06000000-0000-0000-0000-000000000000 +07000000-0000-0000-0000-000000000000 +08000000-0000-0000-0000-000000000000 +09000000-0000-0000-0000-000000000000 +0a000000-0000-0000-0000-000000000000 +0b000000-0000-0000-0000-000000000000 +0c000000-0000-0000-0000-000000000000 +0d000000-0000-0000-0000-000000000000 +0e000000-0000-0000-0000-000000000000 +0f000000-0000-0000-0000-000000000000 +00000000-0001-0000-0000-000000000000 +00000000-0002-0000-0000-000000000000 +00000000-0003-0000-0000-000000000000 +00000000-0004-0000-0000-000000000000 +00000000-0005-0000-0000-000000000000 +00000000-0006-0000-0000-000000000000 +00000000-0007-0000-0000-000000000000 +00000000-0008-0000-0000-000000000000 +00000000-0009-0000-0000-000000000000 +00000000-000a-0000-0000-000000000000 +00000000-000b-0000-0000-000000000000 +00000000-000c-0000-0000-000000000000 +00000000-000d-0000-0000-000000000000 +00000000-000e-0000-0000-000000000000 +00000000-000f-0000-0000-000000000000 +00000000-0100-0000-0000-000000000000 +00000000-0200-0000-0000-000000000000 +00000000-0300-0000-0000-000000000000 +00000000-0400-0000-0000-000000000000 +00000000-0500-0000-0000-000000000000 +00000000-0600-0000-0000-000000000000 +00000000-0700-0000-0000-000000000000 +00000000-0800-0000-0000-000000000000 +00000000-0900-0000-0000-000000000000 +00000000-0a00-0000-0000-000000000000 +00000000-0b00-0000-0000-000000000000 +00000000-0c00-0000-0000-000000000000 +00000000-0d00-0000-0000-000000000000 +00000000-0e00-0000-0000-000000000000 +00000000-0f00-0000-0000-000000000000 +00000000-0000-0001-0000-000000000000 +00000000-0000-0002-0000-000000000000 +00000000-0000-0003-0000-000000000000 +00000000-0000-0004-0000-000000000000 +00000000-0000-0005-0000-000000000000 +00000000-0000-0006-0000-000000000000 +00000000-0000-0007-0000-000000000000 +00000000-0000-0008-0000-000000000000 +00000000-0000-0009-0000-000000000000 +00000000-0000-000a-0000-000000000000 +00000000-0000-000b-0000-000000000000 +00000000-0000-000c-0000-000000000000 +00000000-0000-000d-0000-000000000000 +00000000-0000-000e-0000-000000000000 +00000000-0000-000f-0000-000000000000 +00000000-0000-0100-0000-000000000000 +00000000-0000-0200-0000-000000000000 +00000000-0000-0300-0000-000000000000 +00000000-0000-0400-0000-000000000000 +00000000-0000-0500-0000-000000000000 +00000000-0000-0600-0000-000000000000 +00000000-0000-0700-0000-000000000000 +00000000-0000-0800-0000-000000000000 +00000000-0000-0900-0000-000000000000 +00000000-0000-0a00-0000-000000000000 +00000000-0000-0b00-0000-000000000000 +00000000-0000-0c00-0000-000000000000 +00000000-0000-0d00-0000-000000000000 +00000000-0000-0e00-0000-000000000000 +00000000-0000-0f00-0000-000000000000 +00000000-0000-0000-0001-000000000000 +00000000-0000-0000-0002-000000000000 +00000000-0000-0000-0003-000000000000 +00000000-0000-0000-0004-000000000000 +00000000-0000-0000-0005-000000000000 +00000000-0000-0000-0006-000000000000 +00000000-0000-0000-0007-000000000000 +00000000-0000-0000-0008-000000000000 +00000000-0000-0000-0009-000000000000 +00000000-0000-0000-000a-000000000000 +00000000-0000-0000-000b-000000000000 +00000000-0000-0000-000c-000000000000 +00000000-0000-0000-000d-000000000000 +00000000-0000-0000-000e-000000000000 +00000000-0000-0000-000f-000000000000 +00000000-0000-0000-0100-000000000000 +00000000-0000-0000-0200-000000000000 +00000000-0000-0000-0300-000000000000 +00000000-0000-0000-0400-000000000000 +00000000-0000-0000-0500-000000000000 +00000000-0000-0000-0600-000000000000 +00000000-0000-0000-0700-000000000000 +00000000-0000-0000-0800-000000000000 +00000000-0000-0000-0900-000000000000 +00000000-0000-0000-0a00-000000000000 +00000000-0000-0000-0b00-000000000000 +00000000-0000-0000-0c00-000000000000 +00000000-0000-0000-0d00-000000000000 +00000000-0000-0000-0e00-000000000000 +00000000-0000-0000-0f00-000000000000 +00000000-0000-0000-0000-000000000001 +00000000-0000-0000-0000-000000000002 +00000000-0000-0000-0000-000000000003 +00000000-0000-0000-0000-000000000004 +00000000-0000-0000-0000-000000000005 +00000000-0000-0000-0000-000000000006 +00000000-0000-0000-0000-000000000007 +00000000-0000-0000-0000-000000000008 +00000000-0000-0000-0000-000000000009 +00000000-0000-0000-0000-00000000000a +00000000-0000-0000-0000-00000000000b +00000000-0000-0000-0000-00000000000c +00000000-0000-0000-0000-00000000000d +00000000-0000-0000-0000-00000000000e +00000000-0000-0000-0000-00000000000f +00000000-0000-0000-0000-000000000100 +00000000-0000-0000-0000-000000000200 +00000000-0000-0000-0000-000000000300 +00000000-0000-0000-0000-000000000400 +00000000-0000-0000-0000-000000000500 +00000000-0000-0000-0000-000000000600 +00000000-0000-0000-0000-000000000700 +00000000-0000-0000-0000-000000000800 +00000000-0000-0000-0000-000000000900 +00000000-0000-0000-0000-000000000a00 +00000000-0000-0000-0000-000000000b00 +00000000-0000-0000-0000-000000000c00 +00000000-0000-0000-0000-000000000d00 +00000000-0000-0000-0000-000000000e00 +00000000-0000-0000-0000-000000000f00 +00000000-0000-0000-0000-000000010000 +00000000-0000-0000-0000-000000020000 +00000000-0000-0000-0000-000000030000 +00000000-0000-0000-0000-000000040000 +00000000-0000-0000-0000-000000050000 +00000000-0000-0000-0000-000000060000 +00000000-0000-0000-0000-000000070000 +00000000-0000-0000-0000-000000080000 +00000000-0000-0000-0000-000000090000 +00000000-0000-0000-0000-0000000a0000 +00000000-0000-0000-0000-0000000b0000 +00000000-0000-0000-0000-0000000c0000 +00000000-0000-0000-0000-0000000d0000 +00000000-0000-0000-0000-0000000e0000 +00000000-0000-0000-0000-0000000f0000 +00000000-0000-0000-0000-000001000000 +00000000-0000-0000-0000-000002000000 +00000000-0000-0000-0000-000003000000 +00000000-0000-0000-0000-000004000000 +00000000-0000-0000-0000-000005000000 +00000000-0000-0000-0000-000006000000 +00000000-0000-0000-0000-000007000000 +00000000-0000-0000-0000-000008000000 +00000000-0000-0000-0000-000009000000 +00000000-0000-0000-0000-00000a000000 +00000000-0000-0000-0000-00000b000000 +00000000-0000-0000-0000-00000c000000 +00000000-0000-0000-0000-00000d000000 +00000000-0000-0000-0000-00000e000000 +00000000-0000-0000-0000-00000f000000 +00000000-0000-0000-0000-000100000000 +00000000-0000-0000-0000-000200000000 +00000000-0000-0000-0000-000300000000 +00000000-0000-0000-0000-000400000000 +00000000-0000-0000-0000-000500000000 +00000000-0000-0000-0000-000600000000 +00000000-0000-0000-0000-000700000000 +00000000-0000-0000-0000-000800000000 +00000000-0000-0000-0000-000900000000 +00000000-0000-0000-0000-000a00000000 +00000000-0000-0000-0000-000b00000000 +00000000-0000-0000-0000-000c00000000 +00000000-0000-0000-0000-000d00000000 +00000000-0000-0000-0000-000e00000000 +00000000-0000-0000-0000-000f00000000 +00000000-0000-0000-0000-010000000000 +00000000-0000-0000-0000-020000000000 +00000000-0000-0000-0000-030000000000 +00000000-0000-0000-0000-040000000000 +00000000-0000-0000-0000-050000000000 +00000000-0000-0000-0000-060000000000 +00000000-0000-0000-0000-070000000000 +00000000-0000-0000-0000-080000000000 +00000000-0000-0000-0000-090000000000 +00000000-0000-0000-0000-0a0000000000 +00000000-0000-0000-0000-0b0000000000 +00000000-0000-0000-0000-0c0000000000 +00000000-0000-0000-0000-0d0000000000 +00000000-0000-0000-0000-0e0000000000 +00000000-0000-0000-0000-0f0000000000 +# +# Lexicographical ORDER BY +# +SELECT * FROM t1 ORDER BY CAST(a AS BINARY(16)); +a +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000001 +00000000-0000-0000-0000-000000000002 +00000000-0000-0000-0000-000000000003 +00000000-0000-0000-0000-000000000004 +00000000-0000-0000-0000-000000000005 +00000000-0000-0000-0000-000000000006 +00000000-0000-0000-0000-000000000007 +00000000-0000-0000-0000-000000000008 +00000000-0000-0000-0000-000000000009 +00000000-0000-0000-0000-00000000000a +00000000-0000-0000-0000-00000000000b +00000000-0000-0000-0000-00000000000c +00000000-0000-0000-0000-00000000000d +00000000-0000-0000-0000-00000000000e +00000000-0000-0000-0000-00000000000f +00000000-0000-0000-0000-000000000100 +00000000-0000-0000-0000-000000000200 +00000000-0000-0000-0000-000000000300 +00000000-0000-0000-0000-000000000400 +00000000-0000-0000-0000-000000000500 +00000000-0000-0000-0000-000000000600 +00000000-0000-0000-0000-000000000700 +00000000-0000-0000-0000-000000000800 +00000000-0000-0000-0000-000000000900 +00000000-0000-0000-0000-000000000a00 +00000000-0000-0000-0000-000000000b00 +00000000-0000-0000-0000-000000000c00 +00000000-0000-0000-0000-000000000d00 +00000000-0000-0000-0000-000000000e00 +00000000-0000-0000-0000-000000000f00 +00000000-0000-0000-0000-000000010000 +00000000-0000-0000-0000-000000020000 +00000000-0000-0000-0000-000000030000 +00000000-0000-0000-0000-000000040000 +00000000-0000-0000-0000-000000050000 +00000000-0000-0000-0000-000000060000 +00000000-0000-0000-0000-000000070000 +00000000-0000-0000-0000-000000080000 +00000000-0000-0000-0000-000000090000 +00000000-0000-0000-0000-0000000a0000 +00000000-0000-0000-0000-0000000b0000 +00000000-0000-0000-0000-0000000c0000 +00000000-0000-0000-0000-0000000d0000 +00000000-0000-0000-0000-0000000e0000 +00000000-0000-0000-0000-0000000f0000 +00000000-0000-0000-0000-000001000000 +00000000-0000-0000-0000-000002000000 +00000000-0000-0000-0000-000003000000 +00000000-0000-0000-0000-000004000000 +00000000-0000-0000-0000-000005000000 +00000000-0000-0000-0000-000006000000 +00000000-0000-0000-0000-000007000000 +00000000-0000-0000-0000-000008000000 +00000000-0000-0000-0000-000009000000 +00000000-0000-0000-0000-00000a000000 +00000000-0000-0000-0000-00000b000000 +00000000-0000-0000-0000-00000c000000 +00000000-0000-0000-0000-00000d000000 +00000000-0000-0000-0000-00000e000000 +00000000-0000-0000-0000-00000f000000 +00000000-0000-0000-0000-000100000000 +00000000-0000-0000-0000-000200000000 +00000000-0000-0000-0000-000300000000 +00000000-0000-0000-0000-000400000000 +00000000-0000-0000-0000-000500000000 +00000000-0000-0000-0000-000600000000 +00000000-0000-0000-0000-000700000000 +00000000-0000-0000-0000-000800000000 +00000000-0000-0000-0000-000900000000 +00000000-0000-0000-0000-000a00000000 +00000000-0000-0000-0000-000b00000000 +00000000-0000-0000-0000-000c00000000 +00000000-0000-0000-0000-000d00000000 +00000000-0000-0000-0000-000e00000000 +00000000-0000-0000-0000-000f00000000 +00000000-0000-0000-0000-010000000000 +00000000-0000-0000-0000-020000000000 +00000000-0000-0000-0000-030000000000 +00000000-0000-0000-0000-040000000000 +00000000-0000-0000-0000-050000000000 +00000000-0000-0000-0000-060000000000 +00000000-0000-0000-0000-070000000000 +00000000-0000-0000-0000-080000000000 +00000000-0000-0000-0000-090000000000 +00000000-0000-0000-0000-0a0000000000 +00000000-0000-0000-0000-0b0000000000 +00000000-0000-0000-0000-0c0000000000 +00000000-0000-0000-0000-0d0000000000 +00000000-0000-0000-0000-0e0000000000 +00000000-0000-0000-0000-0f0000000000 +00000000-0000-0000-0001-000000000000 +00000000-0000-0000-0002-000000000000 +00000000-0000-0000-0003-000000000000 +00000000-0000-0000-0004-000000000000 +00000000-0000-0000-0005-000000000000 +00000000-0000-0000-0006-000000000000 +00000000-0000-0000-0007-000000000000 +00000000-0000-0000-0008-000000000000 +00000000-0000-0000-0009-000000000000 +00000000-0000-0000-000a-000000000000 +00000000-0000-0000-000b-000000000000 +00000000-0000-0000-000c-000000000000 +00000000-0000-0000-000d-000000000000 +00000000-0000-0000-000e-000000000000 +00000000-0000-0000-000f-000000000000 +00000000-0000-0000-0100-000000000000 +00000000-0000-0000-0200-000000000000 +00000000-0000-0000-0300-000000000000 +00000000-0000-0000-0400-000000000000 +00000000-0000-0000-0500-000000000000 +00000000-0000-0000-0600-000000000000 +00000000-0000-0000-0700-000000000000 +00000000-0000-0000-0800-000000000000 +00000000-0000-0000-0900-000000000000 +00000000-0000-0000-0a00-000000000000 +00000000-0000-0000-0b00-000000000000 +00000000-0000-0000-0c00-000000000000 +00000000-0000-0000-0d00-000000000000 +00000000-0000-0000-0e00-000000000000 +00000000-0000-0000-0f00-000000000000 +00000000-0000-0001-0000-000000000000 +00000000-0000-0002-0000-000000000000 +00000000-0000-0003-0000-000000000000 +00000000-0000-0004-0000-000000000000 +00000000-0000-0005-0000-000000000000 +00000000-0000-0006-0000-000000000000 +00000000-0000-0007-0000-000000000000 +00000000-0000-0008-0000-000000000000 +00000000-0000-0009-0000-000000000000 +00000000-0000-000a-0000-000000000000 +00000000-0000-000b-0000-000000000000 +00000000-0000-000c-0000-000000000000 +00000000-0000-000d-0000-000000000000 +00000000-0000-000e-0000-000000000000 +00000000-0000-000f-0000-000000000000 +00000000-0000-0100-0000-000000000000 +00000000-0000-0200-0000-000000000000 +00000000-0000-0300-0000-000000000000 +00000000-0000-0400-0000-000000000000 +00000000-0000-0500-0000-000000000000 +00000000-0000-0600-0000-000000000000 +00000000-0000-0700-0000-000000000000 +00000000-0000-0800-0000-000000000000 +00000000-0000-0900-0000-000000000000 +00000000-0000-0a00-0000-000000000000 +00000000-0000-0b00-0000-000000000000 +00000000-0000-0c00-0000-000000000000 +00000000-0000-0d00-0000-000000000000 +00000000-0000-0e00-0000-000000000000 +00000000-0000-0f00-0000-000000000000 +00000000-0001-0000-0000-000000000000 +00000000-0002-0000-0000-000000000000 +00000000-0003-0000-0000-000000000000 +00000000-0004-0000-0000-000000000000 +00000000-0005-0000-0000-000000000000 +00000000-0006-0000-0000-000000000000 +00000000-0007-0000-0000-000000000000 +00000000-0008-0000-0000-000000000000 +00000000-0009-0000-0000-000000000000 +00000000-000a-0000-0000-000000000000 +00000000-000b-0000-0000-000000000000 +00000000-000c-0000-0000-000000000000 +00000000-000d-0000-0000-000000000000 +00000000-000e-0000-0000-000000000000 +00000000-000f-0000-0000-000000000000 +00000000-0100-0000-0000-000000000000 +00000000-0200-0000-0000-000000000000 +00000000-0300-0000-0000-000000000000 +00000000-0400-0000-0000-000000000000 +00000000-0500-0000-0000-000000000000 +00000000-0600-0000-0000-000000000000 +00000000-0700-0000-0000-000000000000 +00000000-0800-0000-0000-000000000000 +00000000-0900-0000-0000-000000000000 +00000000-0a00-0000-0000-000000000000 +00000000-0b00-0000-0000-000000000000 +00000000-0c00-0000-0000-000000000000 +00000000-0d00-0000-0000-000000000000 +00000000-0e00-0000-0000-000000000000 +00000000-0f00-0000-0000-000000000000 +00000001-0000-0000-0000-000000000000 +00000002-0000-0000-0000-000000000000 +00000003-0000-0000-0000-000000000000 +00000004-0000-0000-0000-000000000000 +00000005-0000-0000-0000-000000000000 +00000006-0000-0000-0000-000000000000 +00000007-0000-0000-0000-000000000000 +00000008-0000-0000-0000-000000000000 +00000009-0000-0000-0000-000000000000 +0000000a-0000-0000-0000-000000000000 +0000000b-0000-0000-0000-000000000000 +0000000c-0000-0000-0000-000000000000 +0000000d-0000-0000-0000-000000000000 +0000000e-0000-0000-0000-000000000000 +0000000f-0000-0000-0000-000000000000 +00000100-0000-0000-0000-000000000000 +00000200-0000-0000-0000-000000000000 +00000300-0000-0000-0000-000000000000 +00000400-0000-0000-0000-000000000000 +00000500-0000-0000-0000-000000000000 +00000600-0000-0000-0000-000000000000 +00000700-0000-0000-0000-000000000000 +00000800-0000-0000-0000-000000000000 +00000900-0000-0000-0000-000000000000 +00000a00-0000-0000-0000-000000000000 +00000b00-0000-0000-0000-000000000000 +00000c00-0000-0000-0000-000000000000 +00000d00-0000-0000-0000-000000000000 +00000e00-0000-0000-0000-000000000000 +00000f00-0000-0000-0000-000000000000 +00010000-0000-0000-0000-000000000000 +00020000-0000-0000-0000-000000000000 +00030000-0000-0000-0000-000000000000 +00040000-0000-0000-0000-000000000000 +00050000-0000-0000-0000-000000000000 +00060000-0000-0000-0000-000000000000 +00070000-0000-0000-0000-000000000000 +00080000-0000-0000-0000-000000000000 +00090000-0000-0000-0000-000000000000 +000a0000-0000-0000-0000-000000000000 +000b0000-0000-0000-0000-000000000000 +000c0000-0000-0000-0000-000000000000 +000d0000-0000-0000-0000-000000000000 +000e0000-0000-0000-0000-000000000000 +000f0000-0000-0000-0000-000000000000 +01000000-0000-0000-0000-000000000000 +02000000-0000-0000-0000-000000000000 +03000000-0000-0000-0000-000000000000 +04000000-0000-0000-0000-000000000000 +05000000-0000-0000-0000-000000000000 +06000000-0000-0000-0000-000000000000 +07000000-0000-0000-0000-000000000000 +08000000-0000-0000-0000-000000000000 +09000000-0000-0000-0000-000000000000 +0a000000-0000-0000-0000-000000000000 +0b000000-0000-0000-0000-000000000000 +0c000000-0000-0000-0000-000000000000 +0d000000-0000-0000-0000-000000000000 +0e000000-0000-0000-0000-000000000000 +0f000000-0000-0000-0000-000000000000 +SELECT * FROM t1 ORDER BY CAST(COALESCE(NULL,a) AS BINARY(16)); +a +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000000 +00000000-0000-0000-0000-000000000001 +00000000-0000-0000-0000-000000000002 +00000000-0000-0000-0000-000000000003 +00000000-0000-0000-0000-000000000004 +00000000-0000-0000-0000-000000000005 +00000000-0000-0000-0000-000000000006 +00000000-0000-0000-0000-000000000007 +00000000-0000-0000-0000-000000000008 +00000000-0000-0000-0000-000000000009 +00000000-0000-0000-0000-00000000000a +00000000-0000-0000-0000-00000000000b +00000000-0000-0000-0000-00000000000c +00000000-0000-0000-0000-00000000000d +00000000-0000-0000-0000-00000000000e +00000000-0000-0000-0000-00000000000f +00000000-0000-0000-0000-000000000100 +00000000-0000-0000-0000-000000000200 +00000000-0000-0000-0000-000000000300 +00000000-0000-0000-0000-000000000400 +00000000-0000-0000-0000-000000000500 +00000000-0000-0000-0000-000000000600 +00000000-0000-0000-0000-000000000700 +00000000-0000-0000-0000-000000000800 +00000000-0000-0000-0000-000000000900 +00000000-0000-0000-0000-000000000a00 +00000000-0000-0000-0000-000000000b00 +00000000-0000-0000-0000-000000000c00 +00000000-0000-0000-0000-000000000d00 +00000000-0000-0000-0000-000000000e00 +00000000-0000-0000-0000-000000000f00 +00000000-0000-0000-0000-000000010000 +00000000-0000-0000-0000-000000020000 +00000000-0000-0000-0000-000000030000 +00000000-0000-0000-0000-000000040000 +00000000-0000-0000-0000-000000050000 +00000000-0000-0000-0000-000000060000 +00000000-0000-0000-0000-000000070000 +00000000-0000-0000-0000-000000080000 +00000000-0000-0000-0000-000000090000 +00000000-0000-0000-0000-0000000a0000 +00000000-0000-0000-0000-0000000b0000 +00000000-0000-0000-0000-0000000c0000 +00000000-0000-0000-0000-0000000d0000 +00000000-0000-0000-0000-0000000e0000 +00000000-0000-0000-0000-0000000f0000 +00000000-0000-0000-0000-000001000000 +00000000-0000-0000-0000-000002000000 +00000000-0000-0000-0000-000003000000 +00000000-0000-0000-0000-000004000000 +00000000-0000-0000-0000-000005000000 +00000000-0000-0000-0000-000006000000 +00000000-0000-0000-0000-000007000000 +00000000-0000-0000-0000-000008000000 +00000000-0000-0000-0000-000009000000 +00000000-0000-0000-0000-00000a000000 +00000000-0000-0000-0000-00000b000000 +00000000-0000-0000-0000-00000c000000 +00000000-0000-0000-0000-00000d000000 +00000000-0000-0000-0000-00000e000000 +00000000-0000-0000-0000-00000f000000 +00000000-0000-0000-0000-000100000000 +00000000-0000-0000-0000-000200000000 +00000000-0000-0000-0000-000300000000 +00000000-0000-0000-0000-000400000000 +00000000-0000-0000-0000-000500000000 +00000000-0000-0000-0000-000600000000 +00000000-0000-0000-0000-000700000000 +00000000-0000-0000-0000-000800000000 +00000000-0000-0000-0000-000900000000 +00000000-0000-0000-0000-000a00000000 +00000000-0000-0000-0000-000b00000000 +00000000-0000-0000-0000-000c00000000 +00000000-0000-0000-0000-000d00000000 +00000000-0000-0000-0000-000e00000000 +00000000-0000-0000-0000-000f00000000 +00000000-0000-0000-0000-010000000000 +00000000-0000-0000-0000-020000000000 +00000000-0000-0000-0000-030000000000 +00000000-0000-0000-0000-040000000000 +00000000-0000-0000-0000-050000000000 +00000000-0000-0000-0000-060000000000 +00000000-0000-0000-0000-070000000000 +00000000-0000-0000-0000-080000000000 +00000000-0000-0000-0000-090000000000 +00000000-0000-0000-0000-0a0000000000 +00000000-0000-0000-0000-0b0000000000 +00000000-0000-0000-0000-0c0000000000 +00000000-0000-0000-0000-0d0000000000 +00000000-0000-0000-0000-0e0000000000 +00000000-0000-0000-0000-0f0000000000 +00000000-0000-0000-0001-000000000000 +00000000-0000-0000-0002-000000000000 +00000000-0000-0000-0003-000000000000 +00000000-0000-0000-0004-000000000000 +00000000-0000-0000-0005-000000000000 +00000000-0000-0000-0006-000000000000 +00000000-0000-0000-0007-000000000000 +00000000-0000-0000-0008-000000000000 +00000000-0000-0000-0009-000000000000 +00000000-0000-0000-000a-000000000000 +00000000-0000-0000-000b-000000000000 +00000000-0000-0000-000c-000000000000 +00000000-0000-0000-000d-000000000000 +00000000-0000-0000-000e-000000000000 +00000000-0000-0000-000f-000000000000 +00000000-0000-0000-0100-000000000000 +00000000-0000-0000-0200-000000000000 +00000000-0000-0000-0300-000000000000 +00000000-0000-0000-0400-000000000000 +00000000-0000-0000-0500-000000000000 +00000000-0000-0000-0600-000000000000 +00000000-0000-0000-0700-000000000000 +00000000-0000-0000-0800-000000000000 +00000000-0000-0000-0900-000000000000 +00000000-0000-0000-0a00-000000000000 +00000000-0000-0000-0b00-000000000000 +00000000-0000-0000-0c00-000000000000 +00000000-0000-0000-0d00-000000000000 +00000000-0000-0000-0e00-000000000000 +00000000-0000-0000-0f00-000000000000 +00000000-0000-0001-0000-000000000000 +00000000-0000-0002-0000-000000000000 +00000000-0000-0003-0000-000000000000 +00000000-0000-0004-0000-000000000000 +00000000-0000-0005-0000-000000000000 +00000000-0000-0006-0000-000000000000 +00000000-0000-0007-0000-000000000000 +00000000-0000-0008-0000-000000000000 +00000000-0000-0009-0000-000000000000 +00000000-0000-000a-0000-000000000000 +00000000-0000-000b-0000-000000000000 +00000000-0000-000c-0000-000000000000 +00000000-0000-000d-0000-000000000000 +00000000-0000-000e-0000-000000000000 +00000000-0000-000f-0000-000000000000 +00000000-0000-0100-0000-000000000000 +00000000-0000-0200-0000-000000000000 +00000000-0000-0300-0000-000000000000 +00000000-0000-0400-0000-000000000000 +00000000-0000-0500-0000-000000000000 +00000000-0000-0600-0000-000000000000 +00000000-0000-0700-0000-000000000000 +00000000-0000-0800-0000-000000000000 +00000000-0000-0900-0000-000000000000 +00000000-0000-0a00-0000-000000000000 +00000000-0000-0b00-0000-000000000000 +00000000-0000-0c00-0000-000000000000 +00000000-0000-0d00-0000-000000000000 +00000000-0000-0e00-0000-000000000000 +00000000-0000-0f00-0000-000000000000 +00000000-0001-0000-0000-000000000000 +00000000-0002-0000-0000-000000000000 +00000000-0003-0000-0000-000000000000 +00000000-0004-0000-0000-000000000000 +00000000-0005-0000-0000-000000000000 +00000000-0006-0000-0000-000000000000 +00000000-0007-0000-0000-000000000000 +00000000-0008-0000-0000-000000000000 +00000000-0009-0000-0000-000000000000 +00000000-000a-0000-0000-000000000000 +00000000-000b-0000-0000-000000000000 +00000000-000c-0000-0000-000000000000 +00000000-000d-0000-0000-000000000000 +00000000-000e-0000-0000-000000000000 +00000000-000f-0000-0000-000000000000 +00000000-0100-0000-0000-000000000000 +00000000-0200-0000-0000-000000000000 +00000000-0300-0000-0000-000000000000 +00000000-0400-0000-0000-000000000000 +00000000-0500-0000-0000-000000000000 +00000000-0600-0000-0000-000000000000 +00000000-0700-0000-0000-000000000000 +00000000-0800-0000-0000-000000000000 +00000000-0900-0000-0000-000000000000 +00000000-0a00-0000-0000-000000000000 +00000000-0b00-0000-0000-000000000000 +00000000-0c00-0000-0000-000000000000 +00000000-0d00-0000-0000-000000000000 +00000000-0e00-0000-0000-000000000000 +00000000-0f00-0000-0000-000000000000 +00000001-0000-0000-0000-000000000000 +00000002-0000-0000-0000-000000000000 +00000003-0000-0000-0000-000000000000 +00000004-0000-0000-0000-000000000000 +00000005-0000-0000-0000-000000000000 +00000006-0000-0000-0000-000000000000 +00000007-0000-0000-0000-000000000000 +00000008-0000-0000-0000-000000000000 +00000009-0000-0000-0000-000000000000 +0000000a-0000-0000-0000-000000000000 +0000000b-0000-0000-0000-000000000000 +0000000c-0000-0000-0000-000000000000 +0000000d-0000-0000-0000-000000000000 +0000000e-0000-0000-0000-000000000000 +0000000f-0000-0000-0000-000000000000 +00000100-0000-0000-0000-000000000000 +00000200-0000-0000-0000-000000000000 +00000300-0000-0000-0000-000000000000 +00000400-0000-0000-0000-000000000000 +00000500-0000-0000-0000-000000000000 +00000600-0000-0000-0000-000000000000 +00000700-0000-0000-0000-000000000000 +00000800-0000-0000-0000-000000000000 +00000900-0000-0000-0000-000000000000 +00000a00-0000-0000-0000-000000000000 +00000b00-0000-0000-0000-000000000000 +00000c00-0000-0000-0000-000000000000 +00000d00-0000-0000-0000-000000000000 +00000e00-0000-0000-0000-000000000000 +00000f00-0000-0000-0000-000000000000 +00010000-0000-0000-0000-000000000000 +00020000-0000-0000-0000-000000000000 +00030000-0000-0000-0000-000000000000 +00040000-0000-0000-0000-000000000000 +00050000-0000-0000-0000-000000000000 +00060000-0000-0000-0000-000000000000 +00070000-0000-0000-0000-000000000000 +00080000-0000-0000-0000-000000000000 +00090000-0000-0000-0000-000000000000 +000a0000-0000-0000-0000-000000000000 +000b0000-0000-0000-0000-000000000000 +000c0000-0000-0000-0000-000000000000 +000d0000-0000-0000-0000-000000000000 +000e0000-0000-0000-0000-000000000000 +000f0000-0000-0000-0000-000000000000 +01000000-0000-0000-0000-000000000000 +02000000-0000-0000-0000-000000000000 +03000000-0000-0000-0000-000000000000 +04000000-0000-0000-0000-000000000000 +05000000-0000-0000-0000-000000000000 +06000000-0000-0000-0000-000000000000 +07000000-0000-0000-0000-000000000000 +08000000-0000-0000-0000-000000000000 +09000000-0000-0000-0000-000000000000 +0a000000-0000-0000-0000-000000000000 +0b000000-0000-0000-0000-000000000000 +0c000000-0000-0000-0000-000000000000 +0d000000-0000-0000-0000-000000000000 +0e000000-0000-0000-0000-000000000000 +0f000000-0000-0000-0000-000000000000 +DROP TABLE t1; +# # cmp_item_uuid: IN for non-constants # CREATE TABLE t1 (a UUID, b UUID); @@ -596,10 +1659,10 @@ INSERT INTO t1 VALUES (CAST(CONCAT('2','0000000-0000-0000-0000-000000000003') AS SELECT * FROM t1 ORDER BY a; a 10000000-0000-0000-0000-000000000001 -10000000-0000-0000-0000-000000000002 -10000000-0000-0000-0000-000000000003 20000000-0000-0000-0000-000000000001 +10000000-0000-0000-0000-000000000002 20000000-0000-0000-0000-000000000002 +10000000-0000-0000-0000-000000000003 20000000-0000-0000-0000-000000000003 DROP TABLE t1; # |