MariaDB server is a community developed fork of MySQL server. Started by core members of the original MySQL team, MariaDB actively works with outside developers to deliver the most featureful, stable, and sanely licensed open SQL server in the industry.
Find a file
Sergei Petrunia 4941ac9192 MDEV-32113: utf8mb3_key_col=utf8mb4_value cannot be used for ref
(Variant#3: Allow cross-charset comparisons, use a special
CHARSET_INFO to create lookup keys. Review input addressed.)

Equalities that compare utf8mb{3,4}_general_ci strings, like:

  WHERE ... utf8mb3_key_col=utf8mb4_value    (MB3-4-CMP)

can now be used to construct ref[const] access and also participate
in multiple-equalities.
This means that utf8mb3_key_col can be used for key-lookups when
compared with an utf8mb4 constant, field or expression using '=' or
'<=>' comparison operators.

This is controlled by optimizer_switch='cset_narrowing=on', which is
OFF by default.

IMPLEMENTATION
Item value comparison in (MB3-4-CMP) is done using utf8mb4_general_ci.
This is valid as any utf8mb3 value is also an utf8mb4 value.

When making index lookup value for utf8mb3_key_col, we do "Charset
Narrowing": characters that are in the Basic Multilingual Plane (=BMP) are
copied as-is, as they can be represented in utf8mb3. Characters that are
outside the BMP cannot be represented in utf8mb3 and are replaced
with U+FFFD, the "Replacement Character".

In utf8mb4_general_ci, the Replacement Character compares as equal to any
character that's not in BMP. Because of this, the constructed lookup value
will find all index records that would be considered equal by the original
condition (MB3-4-CMP).

Approved-by: Monty <monty@mariadb.org>
2023-10-19 17:24:30 +03:00
.github Merge 10.5 into 10.6 2023-05-19 14:24:09 +03:00
BUILD Change BUILD scripts to use with-ssl=system 2023-10-03 08:25:31 +03:00
client MDEV-32203 Raise notes when an index cannot be used on data type mismatch 2023-10-03 08:25:31 +03:00
cmake Merge 10.5 into 10.6 2023-09-19 10:47:26 +03:00
dbug Merge branch '10.6.12' into 10.6 2023-02-06 20:18:44 +01:00
debian Merge 10.5 into 10.6 2023-09-19 10:47:26 +03:00
Docs Merge 10.4 into 10.5 2022-09-26 13:34:38 +03:00
extra Merge 10.5 into 10.6 2023-10-19 13:50:00 +03:00
include MDEV-32113: utf8mb3_key_col=utf8mb4_value cannot be used for ref 2023-10-19 17:24:30 +03:00
libmariadb@c0ddc2c8cf New CC 3.3 2023-08-01 16:40:10 +02:00
libmysqld MDEV-32113: utf8mb3_key_col=utf8mb4_value cannot be used for ref 2023-10-19 17:24:30 +03:00
libservices
man Merge 10.5 into 10.6 2023-04-11 16:15:19 +03:00
mysql-test MDEV-32113: utf8mb3_key_col=utf8mb4_value cannot be used for ref 2023-10-19 17:24:30 +03:00
mysys MDEV-32203 Raise notes when an index cannot be used on data type mismatch 2023-10-03 08:25:31 +03:00
mysys_ssl Merge branch '10.4' into 10.5 2023-08-01 11:52:13 +02:00
plugin Merge 10.5 into 10.6 2023-10-19 13:50:00 +03:00
randgen/conf
scripts Merge 10.5 into 10.6 2023-10-06 14:34:01 +03:00
sql MDEV-32113: utf8mb3_key_col=utf8mb4_value cannot be used for ref 2023-10-19 17:24:30 +03:00
sql-bench
sql-common Merge branch '10.5' into 10.6 2023-08-01 15:08:52 +02:00
storage Merge 10.5 into 10.6 2023-10-19 13:50:00 +03:00
strings MDEV-32113: utf8mb3_key_col=utf8mb4_value cannot be used for ref 2023-10-19 17:24:30 +03:00
support-files Merge 10.5 into 10.6 2023-09-11 14:46:39 +03:00
tests Merge 10.5 into 10.6 2023-09-11 14:46:39 +03:00
tpool MDEV-31095 tpool - do not create new worker, if thread creation is pending. 2023-10-04 17:44:13 +02:00
unittest Merge 10.5 into 10.6 2023-04-11 16:15:19 +03:00
vio Merge branch '10.5' into 10.6 2022-11-02 14:33:20 +01:00
win Merge 10.5 into 10.6 2023-09-14 15:25:53 +03:00
wsrep-lib@151d4f8591 galera: wsrep-lib sumbodule update 2023-09-12 00:38:48 +02:00
zlib Merge branch 'merge-zlib' into 10.3 2023-04-20 17:06:19 +02:00
.clang-format
.gitattributes Merge branch '10.5' into 10.6 2022-02-03 17:01:31 +01:00
.gitignore Merge branch '10.5' into 10.6 2023-08-01 15:08:52 +02:00
.gitlab-ci.yml Merge branch '10.5' into 10.6 2023-08-01 15:08:52 +02:00
.gitmodules Merge remote-tracking branch '10.4' into 10.5 2023-03-31 21:32:41 +02:00
appveyor.yml Merge 10.5 into 10.6 2022-07-27 17:52:37 +03:00
BUILD-CMAKE
CMakeLists.txt Merge branch '10.5' into 10.6 2023-09-05 14:44:52 +07:00
config.h.cmake Merge 10.5 into 10.6 2022-10-12 12:14:13 +03:00
configure.cmake Merge 10.5 into 10.6 2023-09-19 10:47:26 +03:00
CONTRIBUTING.md
COPYING
CREDITS CREDITS: re-instate Tencent Cloud 2023-01-25 16:44:26 +11:00
INSTALL-SOURCE
INSTALL-WIN-SOURCE
KNOWN_BUGS.txt
README.md
THIRDPARTY
VERSION bump the VERSION 2023-08-14 13:47:13 -04:00

Code status:

  • Appveyor CI status ci.appveyor.com

MariaDB: The open source relational database

MariaDB was designed as a drop-in replacement of MySQL(R) with more features, new storage engines, fewer bugs, and better performance.

MariaDB is brought to you by the MariaDB Foundation and the MariaDB Corporation. Please read the CREDITS file for details about the MariaDB Foundation, and who is developing MariaDB.

MariaDB is developed by many of the original developers of MySQL who now work for the MariaDB Corporation, the MariaDB Foundation and by many people in the community.

MySQL, which is the base of MariaDB, is a product and trademark of Oracle Corporation, Inc. For a list of developers and other contributors, see the Credits appendix. You can also run 'SHOW authors' to get a list of active contributors.

A description of the MariaDB project and a manual can be found at:

https://mariadb.org

https://mariadb.com/kb/en/

https://mariadb.com/kb/en/mariadb-vs-mysql-features/

https://mariadb.com/kb/en/mariadb-versus-mysql-compatibility/

https://mariadb.com/kb/en/new-and-old-releases/

Help

More help is available from the Maria Discuss mailing list https://launchpad.net/~maria-discuss, MariaDB's Zulip instance, https://mariadb.zulipchat.com/

Live QA for beginner contributors

MariaDB has a dedicated time each week when we answer new contributor questions live on Zulip. From 8:00 to 10:00 UTC on Mondays, and 10:00 to 12:00 UTC on Thursdays, anyone can ask any questions theyd like, and a live developer will be available to assist.

New contributors can ask questions any time, but we will provide immediate feedback during that interval.

Licensing


NOTE:

MariaDB is specifically available only under version 2 of the GNU General Public License (GPLv2). (I.e. Without the "any later version" clause.) This is inherited from MySQL. Please see the README file in the MySQL distribution for more information.

License information can be found in the COPYING file. Third party license information can be found in the THIRDPARTY file.


Bug Reports

Bug and/or error reports regarding MariaDB should be submitted at: https://jira.mariadb.org

For reporting security vulnerabilities see: https://mariadb.org/about/security-policy/

The code for MariaDB, including all revision history, can be found at: https://github.com/MariaDB/server