当前位置:网站首页>MySQL view
MySQL view
2022-07-27 01:53:00 【Palm nine】
step 1: Create student table stu, Insert 3 Bar record .
CREATE TABLE stu
(
s_id INT PRIMARY KEY,
s_name VARCHAR(20),
addr VARCHAR(50),
tel VARCHAR(50)
);
INSERT INTO stu
VALUES(1,‘XiaoWang’,‘Henan’,‘0371-12345678’),
(2,‘XiaoLi’,‘Hebei’,‘13889072345’),
(3,‘XiaoTian’,‘Henan’,‘0371-12345670’);
step 2: Create enrollment form sign, Insert 3 Bar record .
CREATE TABLE sign
(
s_id INT PRIMARY KEY,
s_name VARCHAR(20),
s_sch VARCHAR(50),
s_sign_sch VARCHAR(50)
);
INSERT INTO sign
VALUES(1,‘XiaoWang’,‘Middle School1’,‘Peking University’),
(2,‘XiaoLi’,‘Middle School2’,‘Tsinghua University’),
(3,‘XiaoTian’,‘Middle School3’,‘Tsinghua University’);
step 3: Create a score sheet stu_mark, Insert 3 Bar record .
CREATE TABLE stu_mark (s_id INT PRIMARY KEY ,s_name VARCHAR(20) ,mark int );
INSERT INTO stu_mark VALUES(1,‘XiaoWang’,80),(2,‘XiaoLi’,71),(3,‘XiaoTian’,70);
step 4: Create an exam Peking University View of students
Inquire about :
step 5: Create an exam Tsinghua University View of students 
Inquire about :
step 6:XiaoTian When you enter your grades, you make mistakes and record too many 50 branch , Correct their entry results .
step 7: View the updated views and tables .


step 8: View the creation information of the view .
step 9: Delete the created view .
边栏推荐
- Makefile
- CEPH (distributed storage)
- How should CDC be configured for Oracle cluster mode? I can run normally in stand-alone mode, but I can't read the increment in cluster mode
- iptables
- 识别神器Mx-yolov3
- Pyqt5 qtablewidget setting gives priority to the text on the right
- 正则表达式之小工具系列
- 29shell函数
- Expect interaction free
- LAMP.
猜你喜欢

Virtualization technology KVM

IO function of standard C library

Excel changes the format of scientific counting method into text

使用ECS和OSS搭建个人网盘
![[polymorphism] the detailed introduction of polymorphism is simple and easy to understand](/img/85/7d00a0d9bd35d50635a0e41f49c691.png)
[polymorphism] the detailed introduction of polymorphism is simple and easy to understand

21dns domain name resolution

MySQL索引

Hands on experiment of network and VPC
![[cann training camp] enter media data processing (Part 2)](/img/74/aa08e9fc3c41f0b17ca6866685f426.png)
[cann training camp] enter media data processing (Part 2)

21DNS域名解析
随机推荐
Docter的安装和基础操作
Definition of array
Self signed SSL certificate
Shell (8) cycle
regular expression
ceph(分布式存储)
Project | implement a high concurrency memory pool
HarmonyOS图像处理应用开发实战直播笔记
Shell (10) array and bubble sort
Shell编程规范与变量
MySQL system variables and state variables
Ubuntu12.10安装Mysql5.5(三)
iptables
LAMP.
Small project - self connected campus network
深度学习过程中笔记(待完善)
[polymorphism] the detailed introduction of polymorphism is simple and easy to understand
Shell loop statement
FTP服务
Shell script - automatically deploy DNS services