2015-07-21 113 views
0

我正在使用phpMyAdmin的最新版本(4.4.12)。 當我試圖在數據庫或表的「SQL」 - Tab中運行無效的mysql命令時,phpmyadmin不返回任何錯誤消息。phpMyAdmin沒有錯誤信息

比如我嘗試:

CREATE VIEW test (a, b c) AS SELECT "A" as a, "B" as b, "C" as c 

(「B」後,發現失蹤的逗號!) 運行這個惡意命令phpMyAdmin的返回成功消息(「綠色對勾」)和一個信息,那mysql返回零數據集 - 這對於CREATE命令是正確的。

看來,phpmyadmin沒有檢查mysql錯誤或沒有返回它們。

我曾與舊版本相同的問題(4.4.3)

它是一個錯誤還是我有一個配置錯誤?

編輯:我發現,它有時(!)的作品,如果我發送兩次SQL,但只在複雜的查詢。如果我發送兩次,上面的例子仍然不會拋出錯誤。

另一個例子: INSERT INTO test(a,b c)VALUES(1,2,3); (在「b」之後也缺少逗號) 返回:「插入-1行(查詢花了0.0009秒)」

所以,-1必須是錯誤。但phpMyAdmin返回綠色複選標記而不是錯誤。

我的config.inc.php:

<?php 
/* 
* Generated configuration file 
* Generated by: phpMyAdmin 4.4.12 setup script 
* Date: Thu, 23 Apr 2015 13:25:48 +0200 
*/ 

/* Servers configuration */ 
$i = 0; 

/* Server: localhost [1] */ 
$i++; 
$cfg['Servers'][$i]['verbose'] = ''; 
$cfg['Servers'][$i]['host'] = 'localhost'; 
$cfg['Servers'][$i]['port'] = ''; 
$cfg['Servers'][$i]['socket'] = ''; 
$cfg['Servers'][$i]['connect_type'] = 'socket'; 
$cfg['Servers'][$i]['nopassword'] = true; 
$cfg['Servers'][$i]['auth_type'] = 'config'; 
$cfg['Servers'][$i]['user'] = 'root'; 
$cfg['Servers'][$i]['password'] = ''; 
$cfg['Servers'][$i]['AllowNoPassword'] = true; 
$cfg['Servers'][$i]['tracking_version_auto_create'] = true; 

$cfg['Servers'][$i]['controluser'] = 'pma'; 
$cfg['Servers'][$i]['controlpass'] = ''; 

/* End of servers configuration */ 

$cfg['blowfish_secret'] = '5538d3a45e6924.68498003'; 
$cfg['DefaultLang'] = 'de'; 
$cfg['ServerDefault'] = 1; 
$cfg['UploadDir'] = ''; 
$cfg['SaveDir'] = ''; 
$cfg['CheckConfigurationPermissions'] = false; 
$cfg['AllowArbitraryServer'] = true; 
$cfg['LoginCookieDeleteAll'] = false; 
$cfg['UserprefsDeveloperTab'] = true; 
$cfg['DBG']['sql'] = true; 

$cfg['MaxRows'] = 500; 
$cfg['Order'] = 'DESC'; 
?> 

回答

0

通過phpMyAdmin的運行此無效mysql命令:

CREATE VIEW test (a, b c) AS SELECT "A" as a, "B" as b, "C" as c 

我得到的休耕錯誤消息:

errors were found during analysis. 

     A comma or a closing bracket was expected (near "c" at position 23) 

所以它只有你的版本有這個問題,重新安裝或重新設置e設置。

+0

重新安裝後出現同樣的問題..我已將我的config.inc.php添加到問題 – bytecounter

+0

沒有人知道爲什麼會出現此問題? – bytecounter