Aurora MySQL does not support row format COMPRESSED and falls back
to COMPACT if you try to use it, cuasing column size too large
errors if you try to use it with utf8mb4 collation.
Add 'versionfromdb' to opt-in for VERSION() query.
mariadb_native_moodle_database::get_server_info() has been removed
to avoid the specific override: everything is now managed in the base
method which takes care of both MySQL and MariaDB versioning details.
New protected methods have been added too to improve the testing strategy,
allowing to mock the results from an actual DB connection.
The new testing strategy enables simulating even the Azure scenarios.
Before PHP 8.1, the mysqli extension had MYSQLI_REPORT_OFF as default setting.
With PHP 8.1, it has been changed to MYSQLI_REPORT_ERROR|MYSQLI_REPORT_STRICT
The native driver is not ready to work with this new reporting level,
see MDL-75761 about to considering to improve it.
So this change just ensures that we continue using MYSQLI_REPORT_OFF
with any PHP version.
With MariaDB 10.2.7 the driver was incorrectly returning '' (empty
string) as default for all the columns having null (meaning, no
default).
Also, cover the case in unit tests, it seems that we were already
testing other defaults but not the null case.
The new API works on normal databases (by deleting data based on the
subquery) and also on MySQL (by deleting the data using a weird join
on the subquery).
Implemented with moodle_read_slave_trait
Functionality is triggered by supplying config dboption['readonly'].
See config-dist.php for more info on supported dboptions.
pgsql and mysqli drivers are using this feature. Also added support for
connection timeout for these two drivers.
MySQL v8 has added "groups" to the reserved word list. That is used
as a table name in Moodle so we have to quote it with backticks in the
SQL so that MySQL knows it's being used as an identifier.
- Clumsy fallback only when there is no full-text search support
- Mimic solr tests
- pgsql tokenization using simple configuration
- workaround for mysql '*' search issue
- total results proper calculation
- SQL server FTS support
- Standarize dml full-text search checkings
- Upgrade note about the new dml method
- Set search_simpledb as default engine if no solr config
The following InnoDB file format configuration parameters were deprecated
in MySQL 5.7.7 and are now removed:
- innodb_file_format
- innodb_file_format_check
- innodb_file_format_max
- innodb_large_prefix
File format configuration parameters were necessary for creating tables
compatible with earlier versions of InnoDB in MySQL 5.1.
Now that MySQL 5.1 has reached the end of its product lifecycle,
the parameters are no longer required.
The FILE_FORMAT column was removed from the INNODB_SYS_TABLES and
INNODB_SYS_TABLESPACES Information Schema tables.
Ref: https://dev.mysql.com/doc/relnotes/mysql/8.0/en/news-8-0-0.html
When updating the mysql system to utf8mb4 not all tables are
converted to the row format of compressed or dynamic. If a new
index is created there is a possibility that the table could be
using compact or redundant and then an error will be shown saying
that the index size is too large. This fix handles this exception
and converts the table over to compressed.
- With the patch, 6 positions of scale accuracy are guaranteed
per individual casted value.
- Backed with unit tests, both for varchar and clob.
- Added 2 missing tests about uses of the method with params
and values.
Note: 6 was picked because looking to all databases implementation
postgres was found to be casting to real, aka, 6.