Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 6e7658d

Browse files
committed
Change reporting parameters matching to avoid naming conflicts
1 parent 7a266a2 commit 6e7658d

1 file changed

Lines changed: 6 additions & 9 deletions

File tree

client_source/sqlplus/ut_run.sql

Lines changed: 6 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -189,17 +189,14 @@ declare
189189
l_default_call_param t_call_param;
190190
l_call_params tt_call_params := tt_call_params();
191191
l_force_out_to_screen boolean;
192+
l_param_regex varchar2(20) := '^-([fos])(\=(.*))?$';
192193
begin
193194
for param in(
194-
with
195-
param_vals as(
196-
select regexp_substr(column_value,'-([a-z_]+)\=?(.*)',1,1,'c',1) param_type,
197-
regexp_substr(column_value,'-([a-z_]+)\=?(.*)',1,1,'c',2) param_value
198-
from table(a_params)
199-
where column_value is not null)
200-
select param_type, param_value
201-
from param_vals
202-
where param_type is not null
195+
select regexp_substr(column_value,l_param_regex,1,1,'c',1) param_type,
196+
regexp_substr(column_value,l_param_regex,1,1,'c',3) param_value
197+
from table(a_params)
198+
where column_value is not null
199+
and regexp_like(column_value,l_param_regex)
203200
) loop
204201
if param.param_type = 'f' or l_call_params.last is null then
205202
l_call_params.extend;

0 commit comments

Comments
 (0)