Labels |
Added:
?
|
Category | ⇒ | Installation |
Status | New | ⇒ | Information Required |
Status | Information Required | ⇒ | Discussion |
Labels |
Added:
J4 Issue
|
Bizarrely I just tested this (on windows) and successfully created a database called &(%£""%^(`;
but I agree we should be validating on entry https://stackoverflow.com/questions/9537771/mysql-database-name-restrictions
Status | Discussion | ⇒ | Closed |
Closed_Date | 0000-00-00 00:00:00 | ⇒ | 2018-08-07 13:28:35 |
Closed_By | ⇒ | brianteeman |
Can we please reopen this issue @brianteeman ?
I think the current solution in Joomla 4 codebase
E.g. in mariadb basically everything is allowed[1], so especially something like 'joomla-4', and I am using database names with dashes in them in production on all my servers for years now, without even a single problem. All applications work with this. Why should Joomla enforce something that is not needed?
So the current logic in Joomla 4 is unneeded way too strict. From my point of view, we should change that current regex to some kind of other logic. Maybe we can somehow query the DBMS and ask whether that database exists, that should be a safe way to check if it is a valid name?
Opinions?
I agree that the current solution is way to strict and will prevent installation using valid database names.
The example given in the top post is wrong. joomla-4 is a valid MySQL database name as long as it is quoted. And quoting is handled by Joomla's database layer.
Edit: See the MySQL docs regarding identifiers.
Status | Closed | ⇒ | New |
Closed_Date | 2018-08-07 13:28:35 | ⇒ | |
Closed_By | brianteeman | ⇒ |
Status | New | ⇒ | Fixed in Code Base |
Closed_Date | 0000-00-00 00:00:00 | ⇒ | 2019-02-07 05:52:39 |
Closed_By | ⇒ | Quy |
Status | Fixed in Code Base | ⇒ | Closed |
Closed_Date | 2019-02-07 05:52:39 | ⇒ | 2019-02-07 05:52:40 |
Closed_By | Quy | ⇒ | joomla-cms-bot |
Set to "closed" on behalf of @Quy by The JTracker Application at issues.joomla.org/joomla-cms/15583
Fixed with PR #23704
@mbabker Issue for 4.0-Projects?