摘要: 有时想限制从第几行或者显示几行,这时,就用到LIMIT(限制) 比如在成绩表sc中有这么多数据 我想得到前5行 select score from SC limit 5; 这样就得到了前五行 若想得到从第三行开始之后的5行,则可用以下语句 select score from SC limit 2,5 阅读全文
posted @ 2023-02-26 16:55 若染咩 阅读(66) 评论(0) 推荐(0)
摘要: 在MySQL中,用DISTINCT(去重)关键字去重 select Ssex from Student; 比如在Student表中,查询性别如下 若想要只显示该列的非重复项,则用到distinct select distinct Ssex from Student; 阅读全文
posted @ 2023-02-26 16:31 若染咩 阅读(56) 评论(0) 推荐(0)
2 3
4