Hi All,
We have a query like below
Select Columns
from T1,t2,t3
where t1.c = t2.c2
and t1.c = t3.c3
and t1.Col in
SELECT :Col
FROM xmltable('r/c' passing
xmltype('<r><c>' ||
replace(REPLACE(:Col1 || ', ' ||
DECODE(:Col_2_Decode,
'1',
:Col_1,
'2',
:Col_1,
'') || ',' ||
DECODE(:Col_2_Decode, '2', :Col2, ''),
''''),
',',
'</c><c>') || '</c></r>') columns new_str
varchar2(50) path '.') d
How else we can rewrite this, this seems to be a bit clumsy and also performance wise not ok. I am not in a position to share the exact query with sample data, sorry for the same. Hence I would like to hear from the Pro's on how better or best to have this rewritten by some other way or function built-ins available in 11g. Thanks in advance.