[Phpmyadmin-devel] #4070 Confusing database/table grouping

Marc Delisle marc at infomarc.info
Wed Apr 16 00:18:07 CEST 2014

Le 2014-04-15 15:18, Hugues Peccatte a écrit :
> Hi,
> I would like to talk about this ticket:
> https://sourceforge.net/p/phpmyadmin/bugs/4070/
> The issue is that when you want to limit the number of items (last
> level) by page in navigation tree, you can have an issue with the last
> group.
> Imagine that you set the config to 25 items, you have a first group of
> 20 DB, and another one of 15 DB. Here, the last group will contain only
> 5 items and not all the group. But there is no information that there is
> other children of this group, so you can believe that you see all the
> items of the group.
> I think that we better have to filter on the first level, than on the
> number of the last level items…
> The list of DB could be get by one query:
> select s.*
> (
> select DB_first_level
> from (
> ) t
> ORDER BY DB_first_level ASC
> LIMIT 1, 3
> ) t2
> where 1 = locate(concat(DB_first_level, '_'), concat(s.SCHEMA_NAME, '_'))
> order by s.SCHEMA_NAME;
> (Here, I assume that the first level separator is "_" and that we want 3
> items of first level.)
> (If someone has basics of optimisation and have some idea to improve
> this query, it could be useful.)
> What do you think about removing limit number of last level items and
> replace it by a limit of first level items?
> Or any idea to fix the issue in another way?

Hi Hugues,
you talk about a limit at the "last level" but currently, the
MaxNavigationItems applies at each level, not just the last one. For
example, set it to "2" and you will see two databases per page, two
tables, two columns, etc.

So if you remove this notion, to limit only at the first level, there
might be a display problem when someone has a big number of tables in
one database, or a big number of columns in a table.

The default limit was set to 250 but I'm not sure that it's a good idea.
Seing 250 tables when expanding a database is a lot of tables.

Marc Delisle

More information about the Developers mailing list