Zero filling a report field

garyd1234

Board Regular
Joined
Apr 17, 2003
Messages
103
Hi,
I have a report running which uses a query as its source. One field in the detail sometimes will not have a value after a calculation is done in the SQL statement of the query. I want that field to show 0.00 if there is nothing (null) in it. It won't. How do I get it to show 0.00. I tried using Nz(fieldname, "0.00") in the SQL and it doesn't work. There is no default property for that field on the report. ???

Thanks

Gary
 

Excel Facts

How to change case of text in Excel?
Use =UPPER() for upper case, =LOWER() for lower case, and =PROPER() for proper case. PROPER won't capitalize second c in Mccartney
Can you give a little information about your query? You should be able to generate the 0 values in the query.
 
Upvote 0
Thought about not posting this because I'm not 100% on this, but I think you're supposed to put the NZ function in the Report itself.
 
Upvote 0
Code:
Iif(([Your_Field] Is Null), 0, [Your_Field])
This needs to go in your underlying query. Take out your original field and put this in its place.
 
Upvote 0

Forum statistics

Threads
1,221,537
Messages
6,160,394
Members
451,645
Latest member
hglymph

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top