Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.misc -> Re: DBWR summed scan depth
On Oct 9, 11:03 am, abdoul85 <abdou..._at_gmail.com> wrote:
> hello,
> I'm writing a simple script which shows informations about database.
> The problem is that I have excecute:
>
> select * from v$sysstat dssd where dssd.name='DBWR summed scan depth'
>
> On database ver 9 everything is allright but on ver 10 the row with
> name value = 'DBWR summed scan depth' doesnt' exist.
No, it doesn't.
> How to enable 'DBWR summed scan depth' in my database ?
There is no way, as far as I know.
> or is there any posibility to encourage SELECT to return for example
> "NOT EXIST" string instead of NULL when 'DBWR summed scan depth'
> doesn,t exist ?
'no rows selected' isn't NULL:
SQL> select * from v$sysstat dssd where dssd.name='DBWR summed scan
depth'
2 /
no rows selected
Of course you could use PL/SQL for this particular query:
SQL> declare
2 stat# number; 3 name varchar2(64); 4 class number; 5 val number; 6 statid number; 7 begin 8 select * 9 into stat#, name, class, val, statid 10 from v$sysstat 11 where name = 'DBWR summed scan depth'; 12 dbms_output.put_line(stat#||' '||name||' '||class||' '||val||''||statid);
14 when no_data_found then 15 dbms_output.put_line('Statistic ''DBWR summed scandepth '' does not exist');
Statistic 'DBWR summed scan depth ' does not exist
PL/SQL procedure successfully completed.
SQL> David Fitzjarrell Received on Tue Oct 09 2007 - 11:32:27 CDT
![]() |
![]() |