From bd011d6e64b3d9f8448783fbe7f92b0d03b5cc09 Mon Sep 17 00:00:00 2001 From: Marc Delisle Date: Tue, 10 Feb 2009 17:36:28 +0000 Subject: [PATCH] bug #2568722 [designer] Compound key not shown --- ChangeLog | 1 + pmd_common.php | 7 ++++--- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/ChangeLog b/ChangeLog index eec29ea96..a4d7251cf 100644 --- a/ChangeLog +++ b/ChangeLog @@ -23,6 +23,7 @@ $HeadURL: https://phpmyadmin.svn.sourceforge.net/svnroot/phpmyadmin/trunk/phpMyA if it contains less than MaxExactCountViews, thanks to Virsacer - virsacer + [lang] Polish update, thanks to Fixer - fixeron +- bug #2568722 [designer] Compound key not shown 3.1.2.0 (2009-01-19) - bug #1253252 [display] Can't NULL a column with relation defined diff --git a/pmd_common.php b/pmd_common.php index d52ee67ca..f23c53424 100644 --- a/pmd_common.php +++ b/pmd_common.php @@ -218,11 +218,12 @@ function get_all_keys($unique_only = false) if ($unique_only && ! $index->isUnique()) { continue; } - $column = key($index->getColumns()); - $keys[$schema . '.' .$table . '.' . $column] = 1; + $columns = $index->getColumns(); + foreach ($columns as $column_name => $dummy) { + $keys[$schema . '.' .$table . '.' . $column_name] = 1; + } } } - return $keys; }