Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Undefined Function 'Nz' in expression

Status
Not open for further replies.

dragongunner0351

Programmer
Mar 16, 2006
104
US
Hello all I have a slight problem I am hoping someone can help me with.

I have a query that keeps giving me the following error message:

Undefined Function Nz in expression

Example: Qty Sold: Nz([Quantity Sold],0)

However when I create it this way:
IIf(IsNull([Quantity Sold]),0) I do not get an error but the fields do not calculate they show up blank instead.

Any assistance is greatly appreciated.


 
Double check your references:
when in VBE (Ctrl+G) menu Tools -> References ...

does the database compiles properly ?
menu Debug -> Compiles ...

Hope This Helps, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ181-2886
 
Thanks for the response PHV, aside from the error code I mentioned all seems well. In regards to the References which one should I be concerned with?

Thanks again
 
Again, does the database compiles properly ?

Hope This Helps, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ181-2886
 
In regards to the References which one should I be concerned with
any prefixed with MISSING

Hope This Helps, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ181-2886
 
What happens if you replace this:
IIf(IsNull([Quantity Sold]),0)
with this ?
IIf(IsNull([Quantity Sold]),0,[Quantity Sold])

Hope This Helps, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ181-2886
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top