SQLServer2005 高校教學內容 (SQL 基礎 – 檢視)

angFL發表於2017-04-09

建立檢視

create view IS_Student(sno,sname,grade)
as
    select student.sno,sname,grade
    from student,sc
    where student.sno = sc.sno
        and sdept = `IS` 
        and cno = `2` 
with check option

刪除檢視

drop view IS_student

檢視之間的相互索引

create view IS_s1(sname,grade)
as 
select sno,grade
from IS_student
where grade > 90

相關文章