asnath
asked on
How do I default the null field to zero?
I have summary calculations involving different fields which are sometimes null values. How do I handle those null values and default them to zero in crystal reports.?
Isnull function does check for the null value but is there any built in function like NVL in crystal to do the same functionality as defaulting the field to zero.
Thanks in advance!
~nat
Isnull function does check for the null value but is there any built in function like NVL in crystal to do the same functionality as defaulting the field to zero.
Thanks in advance!
~nat
SOLUTION
membership
Create a free account to see this answer
Signing up is free and takes 30 seconds. No credit card required.
ASKER CERTIFIED SOLUTION
membership
Create a free account to see this answer
Signing up is free and takes 30 seconds. No credit card required.
Goto File > Report Option>
In there, it should read something like "Convert database NuLL values to default" and "Convert Other Null Values to Default"
If you want to apply this to all reports:
Goto File>Options> Reporting Tab>
In there, you should see under that Reading Data section, "Convert other NULL Values to Default"
In there, it should read something like "Convert database NuLL values to default" and "Convert Other Null Values to Default"
If you want to apply this to all reports:
Goto File>Options> Reporting Tab>
In there, you should see under that Reading Data section, "Convert other NULL Values to Default"
ASKER
But I am doing summary of many of these fields this change in the Report options will not work for the real calculations ...is that correct?
If I want to add column1+column2 +column3 + column4+ column5 ....................
In this calculation any one of the field maybe null anytime......so how do i handle this null problem in this summary calculation.
If I want to add column1+column2 +column3 + column4+ column5 ....................
In this calculation any one of the field maybe null anytime......so how do i handle this null problem in this summary calculation.
By setting the defaults and other options, it should take care of this issue. If it does, adding the isnull function around every column will convert it all over for you.
isnull(column1,0)+isnull(c olumn2,0) +isnull(column3,0) + isnull(column4,0)+ isnull(column5,0)
isnull(column1,0)+isnull(c
ASKER
If I do isnull(column1,0)
It says
Too many functions have been given to this function.
What could be wrong with this?
It says
Too many functions have been given to this function.
What could be wrong with this?
SOLUTION
membership
Create a free account to see this answer
Signing up is free and takes 30 seconds. No credit card required.
ASKER
bdreed35 and wykabryan ....
Thank you very much for you help!
~nat
Thank you very much for you help!
~nat
ASKER