Databases Reference
In-Depth Information
Next, APP_USER enters a fetch loop that retrieves rows from the table EMPLOYEES . Note how
the program dbb.pl pauses after each fetch call, without displaying any data yet.
DBB> SELECT employee_id, first_name, last_name, email FROM hr.employees
/
Row 1 fetched. Hit enter to continue fetching ...
Row 2 fetched. Hit enter to continue fetching ...
In a different window from the one where dbb.pl is running, disconnect the session as a DBA.
SQL> ALTER SYSTEM DISCONNECT SESSION '116,23054' POST_TRANSACTION;
System altered.
Move back to the window where dbb.pl is running and keep hitting enter until all rows
have been fetched.
Row 3 fetched. Hit enter to continue fetching ...
Row 107 fetched. Hit enter to continue fetching ...
EMPLOYEE_ID FIRST_NAME LAST_NAME EMAIL
----------- ----------- ----------- --------
198 Donald OConnell DOCONNEL
197 Kevin Feeney KFEENEY
107 Row(s) processed.
The SELECT statement completed without any noticeable interruption. Now it's time to
take a look at the value in the column V$SESSION.FAILED_OVER .
DBB> SELECT failover_type, failover_method, failed_over
FROM v$session
WHERE username='APP_USER'
/
error code: 942, error message: ORA-00942: table or view does not exist (error possi
bly near <*> indicator at char 56 in 'SELECT failover_type, failover_method, failed_
over FROM <*>v$session WHERE username='APP_USER'
')
The SELECT from V$SESSION , which worked previously, failed. This is a strong indication
that session reestablishment has occurred without restoring all the properties of the session.
Let's again enable SELECT_CATALOG_ROLE .
DBB> SET ROLE select_catalog_role
/
0 Row(s) Processed.
DBB> SELECT failover_type, failover_method, failed_over FROM v$session WHERE
username='APP_USER'
/
Search WWH ::




Custom Search