当前位置: 首页 > news >正文

网站建设制作后报告临沂seo

网站建设制作后报告,临沂seo,wordpress如何调用html代码,产品开发思路目录 上篇在这里喔~ 1.数据库约束 1.NULL约束 2.UNIQUE唯一约束 3.DEFAULT默认值约束 4.PRIMARY KEY主键约束 5.FOREIGN KEY外键约束 2.表的设计 1.设计思路​编辑 2.固定套路​编辑 2.1一对一关系 2.2一对多关系 ​编辑 2.3多对多关系 ​编辑​编辑​编辑 3.插入…

目录

上篇在这里喔~

1.数据库约束

1.NULL约束 

2.UNIQUE唯一约束

3.DEFAULT默认值约束

4.PRIMARY KEY主键约束

5.FOREIGN  KEY外键约束

 2.表的设计

 1.设计思路​编辑

 2.固定套路​编辑

2.1一对一关系 

2.2一对多关系

 ​编辑

 2.3多对多关系

 ​编辑​编辑​编辑 

3.插入查询结果

4.聚合查询

 1.统计成绩共有多少

 2.求小锦鲤的总成绩

3.求小锦鲤成绩的平均值

 4.返回Java最高分和c++最低分


上篇在这里喔~

 增删改查

1.数据库约束

1.NULL约束 

create table stu1(id bigint not null);

2.UNIQUE唯一约束

3.DEFAULT默认值约束

create table stu1(id bigint not null unique,name varchar(255) default'无名氏');

4.PRIMARY KEY主键约束

create table stu1(id bigint primary key auto_increment,name varchar(255) default'无名氏');insert into stu1(id) values(1);
insert into stu1() values();
insert into stu1(id) values(8);
insert into stu1(name) values('w');

 

5.FOREIGN  KEY外键约束

create table class(id bigint primary key auto_increment,name varchar(255) not null nuique);
create table stu2(id bigint primary key auto_increment,name varchar default '无名氏',class_id bigint,foreign key (class_id) references class(id));

 

delete from stu2 where class_id is not null;
select * from stu2;
delete from class where id in (1,2);
select * from class;

 

此时可成功删除

 

 2.表的设计

 1.设计思路

 2.固定套路

2.1一对一关系 

2.2一对多关系

 

 2.3多对多关系

create table stu4(id bigint primary key auto_increment,name varchar(255) not null);
create table course(id bigint primary key auto_increment,name varchar(255) not null unique);
create table score(id bigint primary key auto_increment,score decimal(3),student_id bigint,course_id bigint,foreign key (student_id) references stu4(id),foreign key (course_id) references course(id));

  

3.插入查询结果

insert into stu1 values('小金');
insert into stu2(id,name) select id,name from stu1;
select * from stu1;
select * from stu2;

 

4.聚合查询

 1.统计成绩共有多少

select count(score) from score;
select count(*) from score;

 ​​​​​​​

 2.求小锦鲤的总成绩

select sum(score) '小锦鲤总分' from score, stu4 wherestu4.id = score.student_id and stu4.name = '小锦鲤';

3.求小锦鲤成绩的平均值

select avg(score)  '平均分' from score, stu4 where 
stu4.id = score.student_id and stu4.name = '小锦鲤';

 4.返回Java最高分和c++最低分

select max(score) 'java最高分', min(score) 'c++最低分' from score, course
where score.course_id = course.id; 

http://www.zhongyajixie.com/news/1279.html

相关文章:

  • 深圳做营销网站的公司网络营销推广方式都有哪些
  • 传播文化有限公司网站建设推广软件赚钱
  • 广州哪里有学做网站的济南网络推广网络营销
  • 网站建设要学哪些方面百度指数
  • 能自己做的ppt网站厂房网络推广平台
  • 专门做赌博网站犯法吗外媒头条最新消息
  • 怎么自制网页链接seo词库排行
  • java网站开发架构微信引流的十个方法
  • 做网站收费标准营销推广投放
  • 怎样查网站用什么程序做的济南网站优化公司排名
  • 专业网站制作团队公司网站
  • 文成网站建设在线网站流量查询
  • 阿里云iot网站开发引流推广平台有哪些
  • 服务管理系统宁波百度seo排名优化
  • 重庆做网站开发的公司有哪些公司seo是指什么意思
  • 后端开发工程师seo快速排名软件平台
  • logo免费制作平台深圳seo技术
  • 电商网站推荐学校网站建设
  • 做网站荣耀体验服官网windows优化大师官方免费
  • 泡泡资源网seo查询友情链接
  • 西安建设工程信息网人员信息北京网站快速优化排名
  • 长沙做网站的包吃包住4000seo是指搜索引擎营销
  • 做网站的工作要求引擎搜索
  • 网站建设公司的服务器宁波seo教程
  • 做传销网站违法的吗外贸营销渠道
  • 网站建设怎么做网站推广关键词工具
  • 河北网站优化建设软文写作实训总结
  • 优惠券推广网站怎么做百度关键词推广教程
  • 网站被百度k了如何申述免费隐私网站推广
  • 做优化的网站电话sem优化师是做什么的