mySql Database Naming Tip

How to easily keep a tidy overview of databases in phpMyAdmin

phpMyAdmin Screenshot

When dealing with lots of databases and tables in phpMyAdmin, the left Navigation Panel can quickly get quite crowed. PhpMyAdmin offers a nice solution for this problem with so called Stacks. These Stacks can be created, when using predefined Separators for naming databases and tables.

Create Database Stacks

To create Stacks as seen in the Screenshot, just use a underline _ in your database names. The default separator $cfg['NavigationTreeDbSeparator'] can be edited/added in the phpMyAdmin config.inc.php file.

In the following Example the TV-Show databases, TV-Show_Children and TV-Show_Sci-Fi are stacked as TV-Shows because of the prefix TV-Show_.

phpMyAdmin Screenshot

Create Table Stacks

Just as databases, tables can also be stacked. The default separator for table names is a double underline __. This value $cfg['NavigationTreeTableSeparator'] can be edited/added in the phpMyAdmin config.inc.php file.

phpMyAdmin Screenshot

The same concept for naming Database Stacks also applies to Table Stacks. The only difference is the double __ underline separator. As in the example below TV-Shows Tables are stacked based on their Show names.

phpMyAdmin Screenshot

Documentation: PhpMyAdmin Navigation Panel Setup