@@ -68,7 +68,7 @@ class LayerMYSQL extends AbstractLayer
|
|||||||
$req = '
|
$req = '
|
||||||
SELECT
|
SELECT
|
||||||
'.self::protect('TABLE_NAME').' as '.self::protect('name').',
|
'.self::protect('TABLE_NAME').' as '.self::protect('name').',
|
||||||
'.self::protect('TABLE_COMMENT').' as '.self::protect('comment').',
|
'.self::protect('TABLE_COMMENT').' as '.self::protect('comment').'
|
||||||
FROM '.self::protect('TABLES').'
|
FROM '.self::protect('TABLES').'
|
||||||
WHERE
|
WHERE
|
||||||
'.self::protect('TABLE_SCHEMA').' = ?
|
'.self::protect('TABLE_SCHEMA').' = ?
|
||||||
@@ -148,7 +148,7 @@ class LayerMYSQL extends AbstractLayer
|
|||||||
'.self::protect('TABLE_NAME').' as '.self::protect('table').',
|
'.self::protect('TABLE_NAME').' as '.self::protect('table').',
|
||||||
'.self::protect('INDEX_NAME').' as '.self::protect('name').',
|
'.self::protect('INDEX_NAME').' as '.self::protect('name').',
|
||||||
'.self::protect('INDEX_TYPE').' as '.self::protect('type').',
|
'.self::protect('INDEX_TYPE').' as '.self::protect('type').',
|
||||||
'.self::protect('COLUMN_NAME').' as '.self::protect('column').'
|
'.self::protect('COLUMN_NAME').' as '.self::protect('column').',
|
||||||
'.self::protect('NON_UNIQUE').' as '.self::protect('non_unique').'
|
'.self::protect('NON_UNIQUE').' as '.self::protect('non_unique').'
|
||||||
FROM '.self::protect('STATISTICS').'
|
FROM '.self::protect('STATISTICS').'
|
||||||
WHERE
|
WHERE
|
||||||
@@ -170,9 +170,12 @@ class LayerMYSQL extends AbstractLayer
|
|||||||
self::$keys[$index['table']][$index['name']]['columns'][] = $index['column'];
|
self::$keys[$index['table']][$index['name']]['columns'][] = $index['column'];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (isset(self::$keys[$table['name']])) {
|
||||||
return self::$keys[$table['name']];
|
return self::$keys[$table['name']];
|
||||||
|
} else {
|
||||||
|
return array();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
?>
|
?>
|
||||||
|
|||||||
Reference in New Issue
Block a user