lotusseed
asked on
How do I fix this error "a boolean array is required here" in Crystal report?
I use Crystal Report 8.5
I just want to add a formular field to the report but the database fields in my formular contain null value. I've tried the convert null to default value in the Report Options. But it doesn't work. It makes my report shows no result at all. So someone suggested me to convert the null field by creating a newformular field of that null field using if then else.
i.e. database field that contain null are A, B, C, D.
I want to make a new report field that get the value of A+B+C-D
what I did was:
@A = if isnull(A) then 0.00 else A = A
and the same for @B, @C, and @D
@WDV = @A + @B + @C - @D
But then I come across this error "a boolean array is required here" and it show the ( at the @B
How do I get this right?
I just want to add a formular field to the report but the database fields in my formular contain null value. I've tried the convert null to default value in the Report Options. But it doesn't work. It makes my report shows no result at all. So someone suggested me to convert the null field by creating a newformular field of that null field using if then else.
i.e. database field that contain null are A, B, C, D.
I want to make a new report field that get the value of A+B+C-D
what I did was:
@A = if isnull(A) then 0.00 else A = A
and the same for @B, @C, and @D
@WDV = @A + @B + @C - @D
But then I come across this error "a boolean array is required here" and it show the ( at the @B
How do I get this right?
ASKER
@add
if isnull({FasMast.additions} ) then {FasMast.additions} = 0.00
else {FasMast.additions} = {FasMast.additions}
@depre
if isnull({FasMast.book_dep_t otal}) then {FasMast.book_dep_total} = 0.00
else {FasMast.book_dep_total} = {FasMast.book_dep_total}
@pur
if isnull({FasMast.purch_valu e}) then {FasMast.purch_value} = 0.00
else {FasMast.purch_value} = {FasMast.purch_value}
@reval
if isnull({FasMast.reval_adj} ) then {FasMast.reval_adj} = 0.00
else {FasMast.reval_adj} = {FasMast.reval_adj}
@wdv
{@pur}+{@add}+{@reval}-{@d epre}
if isnull({FasMast.additions}
else {FasMast.additions} = {FasMast.additions}
@depre
if isnull({FasMast.book_dep_t
else {FasMast.book_dep_total} = {FasMast.book_dep_total}
@pur
if isnull({FasMast.purch_valu
else {FasMast.purch_value} = {FasMast.purch_value}
@reval
if isnull({FasMast.reval_adj}
else {FasMast.reval_adj} = {FasMast.reval_adj}
@wdv
{@pur}+{@add}+{@reval}-{@d
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Thank you so much, it works now.
ASKER
Thank you very much.
Can you post the actual formulas you are trying to use?
mlmcc