Focal Point
[SOLVED] Change value of output field

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

July 13, 2009, 12:31 PM
WP10601
[SOLVED] Change value of output field
I am only an occassional user of the webfocus product, and hence am no expert.

I have a user who in her wisdom does not want to see Z2 as the output code when displayed as output but rather they want undecided where code Z2 = undecided on the table.
I have other codes in the table which there is no proble with only the Z2.

So when displaying all the codes how do I cange the value of the output field to Undecided instead of the default value of Z2.


Sorry more of an AS400 person than Webfocus

This message has been edited. Last edited by: Kerry,
July 13, 2009, 12:54 PM
Microfich
If I understand that you want to keep the value of the result field 'OUTPUT_CODE' unless the value is 'Z2', one way to do it would be (assuming a length of 25):

  
DEFINE FILE filename
OUTPUT_VALUE/A25 = IF OUTPUT_CODE EQ 'Z2' THEN 'Undecided' ELSE OUTPUT_CODE;
END

TABLE FILE filename
PRINT OUTPUT_VALUE
.
.
.
END
-RUN



WebFOCUS 8105
Windows;
DB2, UDB, SQL Server, Oracle
FOCUS-WebFOCUS since 1981
July 13, 2009, 03:16 PM
WP10601
Dr Microfich,
worked as prescribed with my own variation.
Thank you sir.
July 13, 2009, 04:15 PM
Microfich
A chicken soup pleasure. Please tell all your friends. I'll be here all week.


WebFOCUS 8105
Windows;
DB2, UDB, SQL Server, Oracle
FOCUS-WebFOCUS since 1981