Using Is Not Null in query filter

  • Thread starter Douglas J. Steele
  • Start date
D

Douglas J. Steele

You can't.

I assuming you're trying to use "Is Not Null" instead of a specific value in
your query. That means your query has got the = operator (or Like) between
the table field and the value. Trying to have Field1 = Is Not Null or Field1
Like Is Not Null is invalid syntax.
 
H

Hugh O'Neill

Scott said:
In code, how can i set a control equal to "Is Not Null", so my query
will pickup its value?

Me.choiceYear.Value = is not null

I tried the above code but syntax is wrong. My query is correct
pointing to the form control.


Try:

Not (IsNull(Me.choiceYear.Value))

hth

Hugh
 
S

Scott

In code, how can i set a control equal to "Is Not Null", so my query will
pickup its value?

Me.choiceYear.Value = is not null

I tried the above code but syntax is wrong. My query is correct pointing to
the form control.
 

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

Top