By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
446,327 Members | 1,789 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 446,327 IT Pros & Developers. It's quick & easy.

Nested IIF function

P: n/a
I have the following NZ function :
UPDATE Products SET items = NZ(items,0) + " & Nz(Quantity, 0)

This function sets the null values to zeroes for computational
purposes.

I want to test this NZ function whether or not the function was
invoked(if the value was null you get i True).It will mean that i will
exit the function if item are 0.
I want to do it with a nested IIF function,so at least
i have read that one could do it,but i coudnt make it.The function i
have read in the book is the following:
Iif(Nz(MyVal)="", "No Value",MyVal)
I wonder how cani apply it in my function? If i succeed i will have a
very professional code indeed.
Nov 12 '05 #1
Share this Question
Share on Google+
1 Reply


P: n/a
"Johm" <ke**@abv.bg> wrote in message
news:24**************************@posting.google.c om...
I have the following NZ function :
UPDATE Products SET items = NZ(items,0) + " & Nz(Quantity, 0)

This function sets the null values to zeroes for computational
purposes.
You're permanently changing the null values to 0. If this is just for
'computational purposes' then you probably don't need to do that. What's the
computation? Otherwise why not set the fields to 'required' in the first
place?
I want to test this NZ function whether or not the function was
invoked(if the value was null you get i True).It will mean that i will
exit the function if item are 0.
I want to do it with a nested IIF function,so at least
i have read that one could do it,but i coudnt make it.The function i
have read in the book is the following: Iif(Nz(MyVal)="", "No Value",MyVal)
From what you've said you're talking numbers here, so shouldn't that be:

Iif(Nz(MyVal)=0, "No Value",MyVal)
I wonder how cani apply it in my function? If i succeed i will have a
very professional code indeed.


HTH Mike MacSween
Nov 12 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.