phpMyAdmin应用程序崩溃并显示“致命错误:未捕获的ValueError:mysqli_result::d ata_seek()”

phpMyAdmin application crashes with "Fatal error: Uncaught ValueError: mysqli_result::data_seek()"

提问人:Burak Akat 提问时间:2/13/2021 最后编辑:DharmanBurak Akat 更新时间:6/4/2021 访问量:1352

问:

当我在phpMyAdmin上运行查询时,出现以下错误。我正在使用的查询中的错误是什么?

查询:

SELECT hashtag, total, tarih FROM social_trend WHERE tarih > UNIX_TIMESTAMP() ORDER BY total DESC LIMIT 5

错误:

Fatal error: Uncaught ValueError: mysqli_result::data_seek(): Argument #1 ($offset) must be greater than or equal to 0 in 
C:\xampp\phpMyAdmin\libraries\classes\Dbi\DbiMysqli.php:270 Stack trace: 
#0 C:\xampp\phpMyAdmin\libraries\classes\Dbi\DbiMysqli.php(270): mysqli_result->data_seek(-1) 
#1 C:\xampp\phpMyAdmin\libraries\classes\DatabaseInterface.php(2726): PhpMyAdmin\Dbi\DbiMysqli->dataSeek(Object(mysqli_result), -1) 
#2 C:\xampp\phpMyAdmin\libraries\classes\Display\Results.php(4464): PhpMyAdmin\DatabaseInterface->dataSeek(Object(mysqli_result), -1) 
#3 C:\xampp\phpMyAdmin\libraries\classes\Display\Results.php(4203): PhpMyAdmin\Display\Results->_getSortedColumnMessage(Object(mysqli_result), 'total') 
#4 C:\xampp\phpMyAdmin\libraries\classes\Sql.php(1669): PhpMyAdmin\Display\Results->getTable(Object(mysqli_result), Array, Array, true) 
#5 C:\xampp\phpMyAdmin\libraries\classes\Sql.php(1470): PhpMyAdmin\Sql->getHtmlForSqlQueryResultsTable(Object(PhpMyAdmin\Display\Results), './themes/pmahom...', NULL, Array, false, 0, 0, true, Object(mysqli_result), Array, true) 
#6 C:\xampp\phpMyAdmin\libraries\classes\Sql.php(2255): PhpMyAdmin\Sql->getQueryResponseForNoResultsReturned(Array, '808rpg', 'social_trend', NULL, 0, Object(PhpMyAdmin\Display\Results), NULL, './themes/pmahom...', NULL, Object(mysqli_result), 'SELECT hashtag,...', NULL) 
#7 C:\xampp\phpMyAdmin\import.php(758): PhpMyAdmin\Sql->executeQueryAndGetQueryResponse(Array, false, '808rpg', 'social_trend', NULL, NULL, NULL, NULL, NULL, NULL, 'db_structure.ph...', './themes/pmahom...', NULL, NULL, NULL, 'SELECT hashtag,...', NULL, NULL) 
#8 {main} thrown in C:\xampp\phpMyAdmin\libraries\classes\Dbi\DbiMysqli.php on line 270
mysqli phpmyadmin

评论

1赞 Dharman 2/13/2021
它看起来像是phpMyAdmin的错误。请将其作为错误报告给他们
0赞 Burak Akat 2/13/2021
是的,问题是由 phpMyAdmin 5.0.4 版本引起的。安装版本 4.9.1 解决了该问题。

答:

2赞 George 6/4/2021 #1

这是 MySQL8.0 中的一个错误。在空表上,它会抛出此错误。 我又回到了MySQL 5.7,到目前为止没有任何问题:))

评论

0赞 TheSatinKnight 6/5/2021
由于提出问题的人没有发布他们的phpMyAdmin版本或MySQL版本,因此您提供了不需要这些解决方案的解决方案,这很酷。但是,用户发现解决方案是降级phpMyAdmin而不是MySQL。也许将您的答案更多地呈现为“为我工作”,并考虑下次发布您的phpMyAdmin版本。stackoverflow.com/questions/66184263/......