Focal Point
[CLOSED] Multiple conditions for color highlighting

This topic can be found at:
https://forums.informationbuilders.com/eve/forums/a/tpc/f/7971057331/m/3027010495

November 20, 2010, 08:49 AM
raghuram
[CLOSED] Multiple conditions for color highlighting
Hi All,

In our report we need to highlight the color based on the two conditions.
Please see below for the example.
We have 3 columns( COLUMNA,COLUMNB,COLUMNC)
COLUMNA should be highlighted if COLUMNB EQ Y AND COLUMNC EQ N.
I tried like below but it is not working.
TYPE =DATA,COLUMN=COLUMNA,BACKCOLOR=RGB(144 238 144),JUSTIFY=CENTER,WHEN = (COLUMNB EQ Y AND COLUMNC EQ N),$
Please let us know how can we do this.


Thanks in advance.

Raghu

This message has been edited. Last edited by: Kerry,


WebFOCUS 7.6.7
Windows
Excel, PDF, HTML
November 20, 2010, 10:20 AM
Francis Mariani
You need to COMPUTE a field with the condition, then use that computed field in the styling.

TABLE FILE CAR
PRINT *
COMPUTE FLAG1/A1 = IF SEATS GT 3 AND SALES GT 10000 THEN 'Y' ELSE 'N'; NOPRINT
ON TABLE SET PAGE NOLEAD
ON TABLE SET STYLESHEET *
TYPE=REPORT, GRID=OFF,
FONT='ARIAL', SIZE=8, $
TYPE=DATA, COLOR=BLUE, WHEN= FLAG1 EQ 'Y', $
ENDSTYLE
END



Francis


Give me code, or give me retirement. In FOCUS since 1991

Production: WF 7.7.05M, Dev Studio, BID, MRE, WebSphere, DB2 / Test: WF 8.1.05M, App Studio, BI Portal, Report Caster, jQuery, HighCharts, Apache Tomcat, MS SQL Server
November 22, 2010, 10:31 AM
Senthilvasan S
The same could also be done in the DEFINE since the condition is not based on the aggregated values and the DEFINE FIELD could be used in the WHEN statement.


WebFOCUS 7 6 9
Windows XP
HTML, AHTML, PDF, EXCEL