Yes/No Data Type

F

FL

I have a field with a Yes/No data type that uses a field with a check box on
my form. How do I designing a query to show all records with check mark or
all records without check mark? I've tried Is Null in criteria field and Is
Not Null but this does not work for this type field. Any idea on how to do
this type query?
 
F

fredg

I have a field with a Yes/No data type that uses a field with a check box on
my form. How do I designing a query to show all records with check mark or
all records without check mark? I've tried Is Null in criteria field and Is
Not Null but this does not work for this type field. Any idea on how to do
this type query?

Since a check box value is either -1 or 0 simply use
-1
as criteria on this column to show just the records that have the box
checked, or
0
to show just the records which have the box unchecked.

In the query criteria you could also use Yes (or No) as well as True
(or False) as well as On (or Off) as criteria. Each represents a
number value of -1 (or 0).
 
R

Rick Brandt

FL said:
I have a field with a Yes/No data type that uses a field with a check
box on my form. How do I designing a query to show all records with
check mark or all records without check mark? I've tried Is Null in
criteria field and Is Not Null but this does not work for this type
field. Any idea on how to do this type query?

Test for True or False (no quotes) or negative one and zero.
 

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