mysql_query($sql);$id = mysql_insert_id();在mysql_query()命令中执行INSERT语句后运行该函数时,其结果将是刚创建的行的ID.When that function is run after you've executed your INSERT statement in a mysql_query() command its result will be the ID of the row that was just created. 这篇关于选择最后一个插入ID的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持! 上岸,阿里云!