Expression Total Not working

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Dear All,

I got trouble with the expression (Exp1:) at field at one query

At Design View:

Field: Date Total A Total B Exp1: [Total A] +
[Total B]
Table: Date Table A Table B
Sort:
Show: v v v


When I run this query ( see the datasheet as result of this query), the
column total Exp1: (A+B) just show number (total) only if Total B has
numbers as example below:

Datasheet View:

Date Total A Total B Exp1

1/1/2006 23 35 58
2/2/2006 34
=Blank, no number total at allWhy??
3/2/2006 12 3 15



Would you please help with some solution as usual?

Many thanks

PA
 
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Expr1: Nz([Total A]) + Nz([Total B])

Reason:

NULL + 12 = NULL

therefore,

Nz(Null) + 12 = 12

Nz() turns NULL into zero.

See the VBA Help on Nz() function for more info.
--
MGFoster:::mgf00 <at> earthlink <decimal-point> net
Oakland, CA (USA)

-----BEGIN PGP SIGNATURE-----
Version: PGP for Personal Privacy 5.0
Charset: noconv

iQA/AwUBRAOHa4echKqOuFEgEQKH/ACg4u41q/0H4VWmVTb72EiYPTYWJqoAn2Uj
160V8fg+h2Oa6kHL+lm/E/id
=8uBQ
-----END PGP SIGNATURE-----
 
Dear All,

Many thanks. It does work now.

Best Regards

PA


MGFoster said:
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Expr1: Nz([Total A]) + Nz([Total B])

Reason:

NULL + 12 = NULL

therefore,

Nz(Null) + 12 = 12

Nz() turns NULL into zero.

See the VBA Help on Nz() function for more info.
--
MGFoster:::mgf00 <at> earthlink <decimal-point> net
Oakland, CA (USA)

-----BEGIN PGP SIGNATURE-----
Version: PGP for Personal Privacy 5.0
Charset: noconv

iQA/AwUBRAOHa4echKqOuFEgEQKH/ACg4u41q/0H4VWmVTb72EiYPTYWJqoAn2Uj
160V8fg+h2Oa6kHL+lm/E/id
=8uBQ
-----END PGP SIGNATURE-----
Dear All,

I got trouble with the expression (Exp1:) at field at one query

At Design View:

Field: Date Total A Total B Exp1: [Total A] +
[Total B]
Table: Date Table A Table B
Sort:
Show: v v v


When I run this query ( see the datasheet as result of this query), the
column total Exp1: (A+B) just show number (total) only if Total B has
numbers as example below:

Datasheet View:

Date Total A Total B Exp1

1/1/2006 23 35 58
2/2/2006 34
=Blank, no number total at allWhy??
3/2/2006 12 3 15



Would you please help with some solution as usual?

Many thanks

PA
 

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

Similar Threads

Totals Won't Count Nulls 1
code or Query 2
Sum(IIF statement 1
Group my month and then total each location - query 2
SUM OR TOTAL Q 3
Need Query Help 0
Need Help with Totals Query 24
First and Last Problem 8

Back
Top