目录



商品关系模式(商品编号,商品名,规格,单价)
商店关系模式(商店号,商店名,地址)
供应商关系模式(供应商号,供应商名,地址)

select * from LYL_116_student where Department='计算机' 
- select datediff(yy,Birthday,getdate()) 年龄
- from LYL_116_student where Name= '鹿晗'

select * from LYL_116_student where Name like '_丽%' 
这里需要用到 like 占位符 '_',还有任意符号 '%'
select Sex, count(*) from LYL_116_student group by Sex 这里就直接用 group by 子句将Sex分组查询,然后用 count(*) 计数即可算出男女各有多少人

它里面基本包括了SQL基础教程和高级教程,还有SQL Server一些常用的自带函数。很适合初学者去学习如何去写SQL语句
SQL FOREIGN KEY 约束
https://www.w3school.com.cn/sql/sql_foreignkey.asp

