Wednesday, March 21, 2012

How to change data in a crystal report

Hi all,
I have developed a report where i have field called Required. It has a value either 1 or 0 in database. Now I want to display 'Required' if the value is 1 and 'Not Required' if the value is 0. Plz help me to do so...
Thanks in Advance..
PrashanthHi all,
I came to know that this problem can be sorted out by writing a formula. But I dont know how to write a formula. Anybody help me...
IIF (({HY_PDC_PARAMETER_SET_DTL.REQUIRED}= '1'),'Required' ,'NotRequired' )
When I write so its displayin Required for all rows...

Thanks in Advance,
Prashanth.M|||Hi

there's nothing wrong with the formula u have written,
but if the field is numeric type then you don't need the quotes and if it is a bit data type then you need to check the field with true or false.

You can also try the formula in this way :

if {table.Required}=1 then 'Required' else 'Not Required'

No comments:

Post a Comment