calculating with Null fields

  • Thread starter Thread starter Jean-Paul De Winter
  • Start date Start date
J

Jean-Paul De Winter

Hi,
I have a table with some fields defined as Numeric with default value 0
I want to do some calculating with some of this fields but noticed that
when nothing is entered in those fields they are "Null-field" so no
calculating is possible...

how to solve this?

Thanks
 
hi Jean-Paul,

Jean-Paul De Winter said:
I have a table with some fields defined as Numeric with default value 0
I want to do some calculating with some of this fields but noticed that
when nothing is entered in those fields they are "Null-field" so no
calculating is possible...
how to solve this?

a) set the Required property of the field definition to True.

b) use the Nz() function to replace NULL,
e.g. Nz(Field1, 0) / Nz(Field2, 1)



mfG
--> stefan <--
 
Thanks for the reply..

"required property" does that mean an value MUST be entered even if
tehre is nothing to enter (most field values are looked up in other
tables...

I looked for the Nz() function in my (dutch) version of access but
couldn't find it...
Could you please explain what the ,0 or ,1 mean???
Thanks again



Stefan Hoffmann schreef:
 
hi Jean-Paul,

Jean-Paul De Winter said:
"required property" does that mean an value MUST be entered even if
tehre is nothing to enter (most field values are looked up in other
tables... Yes.

I looked for the Nz() function in my (dutch) version of access but
couldn't find it...
Could you please explain what the ,0 or ,1 mean???
http://www.techonthenet.com/access/functions/advanced/nz.php

These are the values to use, if the specifed field is NULL.

mfG
--> stefan <--
 

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

Back
Top