diff --git a/ChangeLog b/ChangeLog index 1e5b62636..f093f994e 100755 --- a/ChangeLog +++ b/ChangeLog @@ -8,6 +8,8 @@ $Source$ 2005-06-05 Marc Delisle * libraries/functions.js: bug #1207405, invalid SQL when creating table with zero fields + * sql.php: bug #1204951, left frame browse icon alt tag + not updated on emptying table 2005-06-05 Michal Čihař * lang/czech: Update. diff --git a/sql.php b/sql.php index 8bc0dd4d2..5984fc5b5 100644 --- a/sql.php +++ b/sql.php @@ -271,9 +271,11 @@ else { // Defines some variables // A table has to be created or renamed -> left frame should be reloaded // TODO: use the parser/analyzer + if ((!isset($reload) || $reload == 0) && (preg_match('@^CREATE TABLE[[:space:]]+(.*)@i', $sql_query) - || preg_match('@^ALTER TABLE[[:space:]]+(.*)RENAME@i', $sql_query))) { + || preg_match('@^ALTER TABLE[[:space:]]+(.*)RENAME@i', $sql_query) + || preg_match('@^TRUNCATE@i', $sql_query))) { $reload = 1; } // Gets the number of rows per page