Home > Database > Mysql Tutorial > mysql数据库表里首行和末行的取得方法_MySQL

mysql数据库表里首行和末行的取得方法_MySQL

WBOY
Release: 2016-06-01 13:04:27
Original
1657 people have browsed it

取得mysql数据库中表里的第一行:

SELECT mg.* FROM MaxGCC mg ORDER BY mg.JOBID ASC limit 0, 1;

取得mysql数据库中表里的最后一行:

SELECT mg.* FROM MaxGCC mg ORDER BY mg.JOBID desc limit 0, 1;

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