Warning: file_get_contents(/data/phpspider/zhask/data//catemap/1/php/279.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181

Warning: file_get_contents(/data/phpspider/zhask/data//catemap/8/mysql/57.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Php 从当前id中找出下一行的currentid_Php_Mysql - Fatal编程技术网

Php 从当前id中找出下一行的currentid

Php 从当前id中找出下一行的currentid,php,mysql,Php,Mysql,我正在尝试从当前id中选择下一行。 如何找到我当前的id? $qry = mysql_query("SELECT performerid,pic0 FROM ".$table." WHERE id > $currentid ORDER BY id ASC LIMIT 1"); 选择它 $qry=mysql\u查询(“从“$table.”中选择id、performerid、pic0,其中id>$currentid按id排序ASC限制1”)MySQL不支持当前ID的任何概念。如果您正在查找最

我正在尝试从当前id中选择下一行。 如何找到我当前的id?

$qry = mysql_query("SELECT performerid,pic0 FROM ".$table." WHERE id > $currentid ORDER BY id ASC LIMIT 1");
选择它


$qry=mysql\u查询(“从“$table.”中选择id、performerid、pic0,其中id>$currentid按id排序ASC限制1”)

MySQL不支持当前ID的任何概念。如果您正在查找最后插入的ID,则可以通过函数完成