sql – Oracle Apex conditional icons on values in classic report

sql – Oracle Apex conditional icons on values in classic report

The current syntax is wrong. You need to take the status column between each WHEN and THEN clauses in order to get boolean expressions such as

SELECT task_name,
       start_date,
       status,
       CASE 
         WHEN status > 50 THEN
          fa-clock-o is-open
         WHEN status > 100 THEN
          fa-check-circle is-closed
         WHEN status > 150 THEN
          fa-exclamation-circle is-holding
         WHEN status > 200 THEN
          fa-exclamation-triangle is-pending
       END status_icon,
       CASE 
         WHEN status > 10 THEN
          red
         WHEN status > 50 THEN
          green
         WHEN status > 150 THEN
          pink
         WHEN status > 200 THEN
          orange
       END icon_color,
       assigned_to
  FROM eba_ut_chart_tasks
 ORDER BY 2

sql – Oracle Apex conditional icons on values in classic report

Leave a Reply

Your email address will not be published. Required fields are marked *