get all db comments at once, not with single queries

This commit is contained in:
Sebastian Mendel
2008-01-21 13:52:26 +00:00
parent 2bb7833f50
commit b7733ad022
2 changed files with 51 additions and 6 deletions

View File

@@ -270,15 +270,18 @@ require_once './libraries/List.class.php';
{
$dbgroups = array();
$parts = array();
if ($GLOBALS['cfg']['ShowTooltip']
&& $GLOBALS['cfgRelation']['commwork']) {
$db_tooltips = PMA_getDbComments();
}
foreach ($this->getLimitedItems($offset, $count) as $key => $db) {
// garvin: Get comments from PMA comments table
$db_tooltip = '';
if ($GLOBALS['cfg']['ShowTooltip']
&& $GLOBALS['cfgRelation']['commwork']) {
$_db_tooltip = PMA_getDbComment($db);
if ($_db_tooltip) {
$db_tooltip = $_db_tooltip;
}
if (isset($db_tooltips[$db])) {
$db_tooltip = $_db_tooltips[$db];
}
if ($GLOBALS['cfg']['LeftFrameDBTree']