diff --git a/ChangeLog b/ChangeLog index 54c6c8436..7dd98e2bd 100644 --- a/ChangeLog +++ b/ChangeLog @@ -9,6 +9,7 @@ $HeadURL: https://phpmyadmin.svn.sourceforge.net/svnroot/phpmyadmin/trunk/phpMyA - [core] better support for vendor customisation (based on what Debian needs) - rfe #2127987 warn when session.gc_maxlifetime is less than cookie validity - rfe #2100910 configurable default charset for import +- rfe #1913541 link to InnoDB status when error 1005 occurs 3.1.1.0 (not yet released) - patch #2242765 [core] Navi panel server links wrong, diff --git a/libraries/dbi/mysql.dbi.lib.php b/libraries/dbi/mysql.dbi.lib.php index e0d0de6ce..0db781785 100644 --- a/libraries/dbi/mysql.dbi.lib.php +++ b/libraries/dbi/mysql.dbi.lib.php @@ -272,9 +272,11 @@ function PMA_DBI_get_client_info() * @uses $GLOBALS['userlink'] * @uses $GLOBALS['strServerNotResponding'] * @uses $GLOBALS['strSocketProblem'] + * @uses $GLOBALS['strDetails'] * @uses mysql_errno() * @uses mysql_error() * @uses defined() + * @uses PMA_generate_common_url() * @param resource $link mysql link * @return string|boolean $error or false */ @@ -313,6 +315,13 @@ function PMA_DBI_getError($link = null) $error = '#' . ((string) $error_number) . ' - ' . $GLOBALS['strServerNotResponding'] . ' ' . $GLOBALS['strSocketProblem']; } elseif ($error_number == 2003) { $error = '#' . ((string) $error_number) . ' - ' . $GLOBALS['strServerNotResponding']; + } elseif ($error_number == 1005) { + /* InnoDB contraints, see + * http://dev.mysql.com/doc/refman/5.0/en/innodb-foreign-key-constraints.html + */ + $error = '#' . ((string) $error_number) . ' - ' . $error_message . + ' (' . $GLOBALS['strDetails'] . ')'; } else { $error = '#' . ((string) $error_number) . ' - ' . $error_message; }