Hi there, found many posts already that seem to address this issue. However, somehow none of them have helped (yet). Any suggestions to the following?
I have a crosstab query, one row heading, one column heading, one value. In my report, I can correctly display all fields if done normally (by drag-n-drop'ing the field into the report). However, I want to use Nz() or IIF() to make the report show "0" instead of nothing.
In total, there are four fields. Two of them display properly, two of them do not. All contain the same type of data: numeric data from a Count. The two that do not display properly just return errors.
I have tried to diagnose this in a number of ways. Let us call two fields [tt]GoodField[/tt] and [tt]BadField[/tt]. As expected, =Nz([GoodField],0) returns [tt]0[/tt] if GoodField would have displayed nothing, and displays the actual value if it exists. =Nz([BadField],0) just returns [tt]#Error[/tt] though. I tried the IsNull() function--again, as expected, =IsNull([GoodField]) returns [tt]-1[/tt] when =[GoodField] would have returned nothing. And again =IsNull([BadField]) returns [tt]#Error[/tt]!
In fact, just =[BadField] returns an error as well! Any suggestions are greatly appreciated.
I have a crosstab query, one row heading, one column heading, one value. In my report, I can correctly display all fields if done normally (by drag-n-drop'ing the field into the report). However, I want to use Nz() or IIF() to make the report show "0" instead of nothing.
In total, there are four fields. Two of them display properly, two of them do not. All contain the same type of data: numeric data from a Count. The two that do not display properly just return errors.
I have tried to diagnose this in a number of ways. Let us call two fields [tt]GoodField[/tt] and [tt]BadField[/tt]. As expected, =Nz([GoodField],0) returns [tt]0[/tt] if GoodField would have displayed nothing, and displays the actual value if it exists. =Nz([BadField],0) just returns [tt]#Error[/tt] though. I tried the IsNull() function--again, as expected, =IsNull([GoodField]) returns [tt]-1[/tt] when =[GoodField] would have returned nothing. And again =IsNull([BadField]) returns [tt]#Error[/tt]!
In fact, just =[BadField] returns an error as well! Any suggestions are greatly appreciated.