`RememberMeMigration` creates `rememberme_token` table without configured charset & collation · Issue #7985 · contao/contao · GitHub
More Web Proxy on the site http://driver.im/
You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
`lastUsed` datetime NOT NULL COMMENT '(DC2Type:datetime_immutable)',
`class` varchar(100) NOT NULL,
`username` varchar(200) NOT NULL
);
Meaning that whatever default collation is configured on the current MySQL server will be used instead. This can create issues - for example if you want to restore a database backup on another system where that specific default collation of the source system is not available:
$ bin/console c:b:r
[ERROR] An exception occurred while executing a query: SQLSTATE[HY000]: General error: 1273 Unknown collation:
'utf8mb4_uca1400_ai_ci'
Our CREATE TABLE statement should instead include the configured default charset and collation for the current database connection, to keep the table consistent with all the others.
In a fresh Contao 5.3+ installation (i.e. when not migrating from Contao 4.13) the rememberme_token table will be created correctly with the configured charset and collation.
The text was updated successfully, but these errors were encountered:
Uh oh!
There was an error while loading. Please reload this page.
Affected version(s)
5.3+
Description
Our
RememberMeMigration
currently creates therememberme_token
table without a collation:contao/core-bundle/src/Migration/Version503/RememberMeMigration.php
Lines 38 to 44 in d2247a1
Meaning that whatever default collation is configured on the current MySQL server will be used instead. This can create issues - for example if you want to restore a database backup on another system where that specific default collation of the source system is not available:
Our
CREATE TABLE
statement should instead include the configured default charset and collation for the current database connection, to keep the table consistent with all the others.In a fresh Contao 5.3+ installation (i.e. when not migrating from Contao 4.13) the
rememberme_token
table will be created correctly with the configured charset and collation.The text was updated successfully, but these errors were encountered: