oracle 完整的 存储过程 触发器 视图 的简单例子???简单的语法结构和语句??、

解决方案 »

  1.   

    参考一下:http://blog.chinaunix.net/u1/59114/showart_469405.html
      

  2.   

    存储过程:http://topic.csdn.net/u/20081026/21/04c0693f-41df-42fd-ac60-a04122232ac2.html触发器:
    http://topic.csdn.net/u/20081026/11/4d1160d9-f3d1-44ef-a4f6-772e546c1cde.html视图:http://topic.csdn.net/u/20081103/13/4cc97840-06d4-4dcb-b9b3-744fb94c9228.html
      

  3.   

    创建视图:
    create view xuesheng1
    as 
         select 学号,姓名 from 学生 
              where exists (select 课程号 from 课程  
                                 where 课程号='C1' and exists (select 成绩 from 选课 where 系编号='D1'and 成绩<60 ));
    创建存储过程:
    create or replace procedure select_student
    (cur out select_08)
    as
    begin
        open cur for
              select xh.xm,zym,xbcssj,zxf from xs
                     order by xh;
    end;
    创建触发器:
    create trigger cs_kc_avg_del
           instead of delete on cs_kc_avg for each row
    begin
        delete from xs_kc where xh=:old.xh;
    end cs_kc_avg_del;
    简单的用例仅供参考!