Create a blank field seen as a value (not a character)

E

Eguay

I need to write some SQL that will insert a value from another query and if
that field is empty, to enter a blank. Sounds simple right? I have been using
this SQL:

IIf(Val([qrySpeciated Results].[UAS3] Is Not Null),(Val([qrySpeciated
Results].[UAS3]))," ")

The problem is that later I need to do a calculation on this field, and the
" " is seen as a character. I cannot enter a zero instead of a " " because a
blank and a zero are viewed as two different things in this analysis.

Any suggestions on how to enter a blank that is seen as a value?

Any help would be much appreciated!
Thanks.
 
B

Brendan Reynolds

The 'blank' value that is not a 'character' is Null. Or, to put it another
way, the only 'blank' value that is valid in a numeric field (or expression)
is Null. And *not* returning Null is all your expression does. So if you
want a 'blank' value that is not a 'character' don't use the expression,
because the expression is the only thing that is preventing this. Refer
directly to the field instead.

If you're having difficulty handling Null values in the later calculation,
post a question on that and someone here may be able to help you find
another solution.
 
Top