MySQL创建视图v_score,显示学号,姓名,课程号,课程名,成绩。
这是一般的语法结构, 具体还需要提供下学生表、成绩表和选课表才能确定具体字段名称
create view v_score as
select s.stuno,s.stuname,c.cid,c.cname,sc.score from student s , course c,score sc where s.stuno=c.stuno and sc.cid=c.cid
create view v_score as
select stuno,stu_name ,cno,cname,score from student st,score sc,course cs where st.stuno=sc.stuno
and sc.cno=cs.cno
您好,我是有问必答小助手,您的问题已经有小伙伴解答了,您看下是否解决,可以追评进行沟通哦~
如果有您比较满意的答案 / 帮您提供解决思路的答案,可以点击【采纳】按钮,给回答的小伙伴一些鼓励哦~~
ps:问答VIP仅需29元,即可享受5次/月 有问必答服务,了解详情>>>https://vip.csdn.net/askvip?utm_source=1146287632