You can also use "neq"
ContactCnt neq 'Do Not Contact'
-- Sam
-
-Original Message-
From: VAN VLIET, SCOTT E (SBCSI) [mailto:[EMAIL PROTECTED]]
Sent: Thursday, April 18, 2002 11:13 AM
To: CF-Talk
Subject: RE: using != in a filed with a null v
CF-Talk
Subject: RE: using != in a filed with a null value
> The weird thing is if I use that with my whole query which is
>
> Select * From customerLeads
> Where TodaysDate = '#DateFormat("TodaysDate", "mm/dd/yy")#'
> And Email Like '%@%'
&g
> The weird thing is if I use that with my whole query which is
>
> Select * From customerLeads
> Where TodaysDate = '#DateFormat("TodaysDate", "mm/dd/yy")#'
> And Email Like '%@%'
> And Email Like '%.%'
> And ContactCnt != 'Do Not Contact' Or ContactCnt is Null
>
> It totally ignores the date p
The weird thing is if I use that with my whole query which is
Select * From customerLeads
Where TodaysDate = '#DateFormat("TodaysDate", "mm/dd/yy")#'
And Email Like '%@%'
And Email Like '%.%'
And ContactCnt != 'Do Not Contact' Or ContactCnt is Null
It totally ignores the date part and grabs ever
Couldnt you use
Where ContactCNT != 'Do Not Contact' OR ContactCNT is NULL
HTH,
Tim P.
- Original Message -
From: "Ben Densmore" <[EMAIL PROTECTED]>
To: "CF-Talk" <[EMAIL PROTECTED]>
Sent: Thursday, April 18, 2002 1:06 PM
Subject: using != in a filed with a null value
> Can someone tel
use IS NULL or IS NOT NULL
Quoting Ben Densmore <[EMAIL PROTECTED]>:
> Can someone tell me if there is a better way to write a query than using
>
> !=? I have a field in my database that stores info on how many times a
> sales person has contacted a customer or if the customer ordered or
Ben,
> Would I be better off setting a default value of 0 in the database field.
>
If all you're after is a Yes or No to "Can I contact this person?" then you
would be much better off having an bit or an integer that you can switch
between 1 for yes and 0 for no.
Stephen
_
why not say
Where ContactCNT != 'Do Not Contact' OR ContactCNT = NULL
"Success is a journey, not a destination!!"
Doug Brown
- Original Message -
From: "Ben Densmore" <[EMAIL PROTECTED]>
To: "CF-Talk" <[EMAIL PROTECTED]>
Sent: Thursday, April 18, 2002 10:06 AM
Subject: using != in
8 matches
Mail list logo