RE: Help with HTML formatting in saved search result
Hi everyone. I am having difficulty getting this search to run with conditional HTML formatting in the results. I keep running into either the page returning a “An unexpected error occurred…” error or the search column returning “Error: Invalid Expression”.
CASE WHEN {locationnohierarchy} = ‘My Location’
AND SUM(CASE WHEN TO_CHAR({trandate},’MON’) = ‘JUL’ THEN {amount} ELSE NULL END)
BETWEEN .97 * 1836674.72 AND 1.03 * 1836674.72
THEN ‘<b><span style=”color:#ADFF2F;”>’ || SUM(CASE WHEN TO_CHAR({trandate},’MON’) = ‘JUL’ THEN {amount} ELSE NULL END) || </span></b>’
ELSE NULL
END
Any help is appreciated, thanks!
I personally expect you to have more issues trying to use SUM over the html strings. Although it probably isnt what you want, I’d try getting rid of the SUM’s to at least get the syntax correct first.
The most obvious problem that is seen here is the missing single quote in front of </span></b>'