query calculations

G

Guest

I have a cross tab query that I am using to produce a
report and do some calculations. The calculations do not
seem to be working. My query results are...
Jan Feb my results should be Jan Feb Tot
year1 1 2 year1 1 2 3
year2 2 year2 2 2
year3 4 year3 4 4

But, this is what I get
Jan Feb Tot
year1 1 2 3
year2 2
year3 4

Help please...
 
J

John Spencer (MVP)

It looks as if you are running into the fact that one null in a calculation
means the result is NULL. You will need to use the NZ function (Null to Zero)
in either your query or your code in the report.

In the report something like
Nz(Jan,0) + Nz(Feb,0)


In the Query, something like
Val(Nz(YourCalculationField,0))
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top