MySQL day3数据检索

数据检索

检索所有列

select * form 表名

image

检索单个列

select 列名 from 表名

image

检索多个列

select 列名1,列名2 from 表名

image

检索不同行

distinct

image

限制结果

限制行数

从第1行开始,共5行

image

从第5行开始,共5行

第一个数为开始位置,第二个数为要检索的行数。
image

猜你喜欢

转载自blog.csdn.net/qq_42233374/article/details/114271234