摘要:
select * from v$sql;select * from V$SQLAREA;SELECT * FROM(SELECT substr(sql_text,1,40) sql, buffer_gets, executions, buffer_gets/executions "Gets/Exec", hash_value,address FROM V$SQLAREA WHERE buffer_... 阅读全文
摘要:
SELECT FOR UPDATE 光标为了对正在处理(查询) 的行不被另外的用户改动,oracle 提供一个 FOR UPDATE 子句来对所选择的行进行锁住.--写订票的存储过程 create or replace procedure get_ticket(no number) as sl number; no_ticket exception; begin --<1>查出余数(加... 阅读全文
摘要:
学号 学生姓名 课程名称 成绩(只显示每科最高分)oracle 里可以这样用:select a.studentid as "学 号",studentname "学生姓名",subjectname "课程名称",mark "成 绩"from student a , subject b , grade cwhere a.studentid = c.studentidand b.subjectid = ... 阅读全文
摘要:
select * from (select rownum as num,emp.* from emp) where num >= 9 and num <= 12; 阅读全文