Home > Database > Mysql Tutorial > mysql中获取下一个从增长的id值

mysql中获取下一个从增长的id值

WBOY
Release: 2016-06-07 16:15:02
Original
1113 people have browsed it

mysql中获取下一个自增长的id值 简单的一句话搞定: 其中的 TABLE_SCHEMA='wanku' 代表数据库名称 TABLE_NAME='wankudata' 代表数据表的名称 SELECT auto_increment FROM information_schema.`TABLES` WHERE TABLE_SCHEMA='wanku' AND TABLE_NAME='wankudata'

mysql中获取下一个自增长的id值

简单的一句话搞定:

其中的 TABLE_SCHEMA='wanku' 代表数据库名称

   TABLE_NAME='wankudata' 代表数据表的名称

SELECT auto_increment FROM information_schema.`TABLES` WHERE TABLE_SCHEMA='wanku' AND TABLE_NAME='wankudata';

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template