![cf8b7de44fead4827cdee9b7f03d40ba.png](https://i-blog.csdnimg.cn/blog_migrate/4f290e817337c5c7fd484b6784c24c0c.jpeg)
今天给大家出几个题目,看看大家掌握的怎么样?如果没有下面4表到上一篇文章找哦!
May:看完这篇文章保证你学会sql的增删改zhuanlan.zhihu.com![011ef5d6f7960595f40312c7f993b76e.png](https://i-blog.csdnimg.cn/blog_migrate/b03457ddea68ed949a5d038d7a0fe3f2.jpeg)
做题之前先把昨天改复杂的表变简单了
ALTER TABLE student RENAME stu;
UPDATE stu set s_name='赵雷' WHERE stu_id='01';
ALTER TABLE stu CHANGE stu_id s_id VARCHAR(20);
![62ab758370ed72fcb25e783b3079a30e.png](https://i-blog.csdnimg.cn/blog_migrate/32fbe47934740bf3a19821a338f2383d.jpeg)
![f209e96b308f88fed6c59aa3e499b30d.png](https://i-blog.csdnimg.cn/blog_migrate/b33b39437f26e85c7d0a424ec2e24dd3.png)
![fa42b65b5bcf71ad23d96f9a9bd0bb9a.png](https://i-blog.csdnimg.cn/blog_migrate/ace17bf7c18af1d69ea8e51184157968.jpeg)
![07db8026d91a7b0c7a3f3481206bd9a1.png](https://i-blog.csdnimg.cn/blog_migrate/bf654d9e834c823b3bca21e5d1406139.png)
题目与讲解:
# 1.查找学生表stu的所有记录
SELECT*FROM stu;
![35b22b634a958dbaa1d5c8467ff47c27.png](https://i-blog.csdnimg.cn/blog_migrate/c1b1f474d754ccd461e03ada4499a8ae.jpeg)
# 2.查找所有学生的学号、姓名
SELECT s_id,s_name FROM stu;
![a060f65f03cdeff1e34e523564fe6c54.png](https://i-blog.csdnimg.cn/blog_migrate/9f12b67b6b9a9230946caed0689f30ec.png)
# 3.查找学生编号为01的学生信息
SELECT * FROM stu WHERE s_id='01';
![efc831244c2663e3b13ebcae60ba2499.png](https://i-blog.csdnimg.cn/blog_migrate/f6f97a120ddfdceabad55c6975e06c34.jpeg)
# 4.查找男性同学的学生编号、学生姓名;
SELECT s_id,s_name FROM stu WHERE s_sex='男';
![2d9d0a143bb248dee21862b4ea5c8c33.png](https://i-blog.csdnimg.cn/blog_migrate/d7fa0f24eeb284f3309196c3d9e7b59e.png)
# 5.查找本月过生日的同学信息