02資料庫查詢
阿新 • • 發佈:2020-11-08
資料使用where子句
資料庫中可以使用where子句進行搜尋條件過濾
select * from table where 條件
查詢出python成績大於60分以上的學員資訊
SELECT name,python_score FROM score WHERE python_score >=60;
where子句的操作符
SELECT name,python_score FROM score WHERE python_score=92
SELECT name,python_score FROM score WHERE python_score BETWEEN 90 AND 100
SELECT name,python_score FROM score WHERE python_score BETWEEN 90 AND 100 ORDER BY python_score DESC