CASE statement (or similar functionality) in interactive report?
mblakeneMar 16 2010 — edited Mar 16 2010Hello,
I've written a report based on an anonymous block of PL/SQL that allows me to show a different colored icon on the report based on the value of one of the columns - show green if value is less than x, show yellow if value is between x and y, and show red if value is greater than y.
Here is the code block:
for i in (select proj_id, proj_name,
CASE
WHEN proj_cost < 10 THEN '<img src="#APP_IMAGES#green-circle.jpg">'
WHEN proj_cost > 10 and proj_cost <15 THEN '<img src="#APP_IMAGES#yellow-circle.jpg">'
WHEN proj_cost > 15 THEN '<img src="#APP_IMAGES#red-circle.jpg">'
ELSE NULL
END proj_cost
from project)
loop
htp.p('<p>' || i.proj_id || ', ' || i.proj_name || i.proj_cost ||'</p>');
end loop;
Can I do something similar with an interactive report? I want the flexibility of the interactive report but the ability to still include this customer requirement in the report.
Thanks!
-melissa