I have a metabase which contains references to databases on a user group basis (so every user has a group column, and databases are linked to groups). In my php script, I used to be able to get the allowed tables for a user (under MySQL 5.5) with the following query:
The last check (to the information_schema database) was only included to make sure no non-existent databases are presented to the user. After upgrading to MariaDB 5.5.30, this is not working anymore, it simply returns an empty result set.
Currently, I've removed the extra check on the existence of the database:
which works, but does risk showing non-existent databases.
I've also tried to work with an inner join:
which also works, but is semantically less attractive to me.
I expected MariaDB to work with the same query that worked under MySQL 5.5, so I think this should be fixed.