<<

Bugzilla::DB::MariaDB

NAME

Bugzilla::DB::MariaDB - Bugzilla database compatibility layer for MariaDB

DESCRIPTION

This module overrides methods of the Bugzilla::DB module with MariaDB specific implementation. It is instantiated by the Bugzilla::DB module and should never be used directly.

For interface details see Bugzilla::DB and DBI.

METHODS

BUILDARGS

This method is called by Moo when creating a new object. It turns the flat named arguments from new() and puts them into the dsn, user, pass, and attr attributes.

on_dbi_connected

This method is called by DBI when a connection is established. It sets various connection-specific attributes which are nessessary for the database to function correctly. Because the database can be reconnected to any required session variables must be set here.

Undocumented methods: utf8_charset, utf8_collate, default_row_format'

utf8_charset

Returns the name of the charset to use for utf8 columns. This comes from the Bugzilla->params->{utf8} parameter. It can be either true, false, or utf8mb4

utf8_collate

Returns the name of the collation to use for utf8 columns. When utf8_charset is utf8mb4 this is utf8mb4_unicode_520_ci. Otherwise it is utf8_general_ci.

default_row_format

Returns the default row format to use for tables. When utf8_charset is utf8mb4 this is DYNAMIC for most tables, and COMPRESSED for several table that benefit from compression.

When utf8_charset is utf8 this is COMPACT for all tables.

sql_date_format

Returns the SQL date format string for the current database.

bz_explain

Returns the EXPLAIN output for the given SQL statement.

bz_last_key

Returns the last auto-increment key generated by the database.

sql_position

Returns the SQL position function for the current database.

sql_fulltext_search

Returns the SQL fulltext search function for the current database.

sql_iposition

Returns the SQL position function for the current database, but case-insensitive.

bz_enum_initial_values

Returns the initial values for an ENUM column.

sql_group_by

Returns the SQL GROUP BY clause for the current database.

sql_limit

Returns the SQL LIMIT clause for the current database.

sql_not_regexp

Returns the SQL NOT REGEXP operator for the current database.

sql_string_concat

Returns the SQL string concatenation operator for the current database.

sql_date_math

Returns the SQL date math operator for the current database.

sql_to_days

Returns the SQL to_days function for the current database.

bz_check_server_version

Returns true if the database server version is at least the given

sql_from_days

Returns the SQL from_days function for the current database.

sql_regexp

Returns the SQL REGEXP operator for the current database.

sql_istring

Returns the SQL string case-insensitive operator for the current database.

sql_group_concat

Returns the SQL GROUP_CONCAT function for the current database.

bz_setup_database

Sets up the database for use with Bugzilla.

bz_db_is_utf8

Returns true if the database is using UTF-8.

<<