Conditional formatting based on sql query result

Kfir Ratson September 2, 2014

Hi,

I am using the SQL Macro to get results from a database.

What is the way to color each result based on the value returned from my query?

So for example, if I get value > 50, color the cell background in Red and if < 50, color the cell background in Green...

Thanks!

2 answers

0 votes
Eugene Domingo October 31, 2014

How would you do that?

0 votes
Bob Swift OSS (Bob Swift Atlassian Apps)
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
September 2, 2014

Use a case statement in your sql to distinguish the cases and apply the appropriate surrounding text. The easiest way is to use output=wiki and the color or similar macros.

Suggest an answer

Log in or Sign up to answer