-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathparms.sql
executable file
·46 lines (46 loc) · 1.49 KB
/
parms.sql
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
----------------------------------------------------------------------------------------
--
-- File name: parms.sql
-- Purpose: Display parameters and values.
-
-- Author: Kerry Osborne
--
-- Usage: This scripts prompts for three values, all of which can be left blank.
--
-- name: the name (or piece of a name) of the parameter(s) you wish to see
--
-- isset: "TRUE" or "T" to see only nondefault parameters
--
-- show_hidden: "Y" to show hidden parameters as well
--
---------------------------------------------------------------------------------------
set lines 155
col name for a50
col value for a70
col isdefault for a8
col ismodified for a10
col isset for a10
select name, value, isdefault, ismodified, isset
from
(
select flag,name,value,isdefault,ismodified,
case when isdefault||ismodified = 'TRUEFALSE' then 'FALSE' else 'TRUE' end isset
from
(
select
decode(substr(i.ksppinm,1,1),'_',2,1) flag
, i.ksppinm name
, sv.ksppstvl value
, sv.ksppstdf isdefault
-- , decode(bitand(sv.ksppstvf,7),1,'MODIFIED',4,'SYSTEM_MOD','FALSE') ismodified
, decode(bitand(sv.ksppstvf,7),1,'TRUE',4,'TRUE','FALSE') ismodified
from x$ksppi i
, x$ksppsv sv
where i.indx = sv.indx
)
)
where name like nvl('%¶meter%',name)
and upper(isset) like upper(nvl('%&isset%',isset))
and flag not in (decode('&show_hidden','Y',3,2))
order by flag,replace(name,'_','')
/