5、执行查询语句:select*fromemp;用户B也有一张EMP表,同样要查询select*fromemp;这样他们两条语句在文本上是一模一样的,他们的HASH值也会一样,但是由于涉及到查询的相关表不一样,他们事实上是无法共享的。假如这时候用户C又要查询同样一条语句,他查询的表为scott下的公有同义词,还有就是SCOTT也查询同样一张自己的表emp,情况会是如何呢?代码:SQL> connect a/aConnected.SQL> create table emp ( x int );Table created.SQL> select * from emp;n
6、o rows selectedSQL> connect b/bConnected.SQL> create table emp ( x int );Table created.SQL> select * from emp;no rows selectedSQL> conn scott/tigerConnected.SQL> select * from emp;SQL> conn c/cConnected.SQL> select * from emp;SQL> conn/as sysdbaConnected.SQL> select address,hash_valu
7、e, executions, sql_text 2 from v$sql 3 where upper(sql_text) like 'SELECT * FROM EMP%' 4 /ADDRESS HASH_VALUE EXECUTIONS SQL_TEXT-------- ---------- ---------- ------------------------78B89E9C 3011704998 1 select * from emp78B89E9C 3011704998 1 select * fro