There are also wildcard operators you can use in a LIKE expression that will
act as * placeholders, so you can effectively do a..d..e and it doesn't
matter what letters are inbetween. Check your BOL, a s i can't remember the
actual characters are.


--
snake 

-----Original Message-----
From: Barney Boisvert [mailto:[EMAIL PROTECTED] 
Sent: 02 September 2005 01:33
To: CF-Talk
Subject: Re: Where ClientName Like '[a-d]%' - How would you actually do
this?

LIKE doesn't support regular expressions.  You'd have to do "cn LIKE 'a%' OR
cn LIKE 'b%'...".  However, definitely check your DB's documentation to see
if there is a regular expression operator.  MySQL has REGEX, for example,
which is the same as LIKE, except that it understands regex instead of
percent signs.

cheers,
barneyb

On 9/1/05, Les Mizzell <[EMAIL PROTECTED]> wrote:
> Basically, I'm trying to pull up a number of names where the first 
> letter is in a RANGE being passed by an url variable.
> 
> Something like:
> 
> Select from myTABLE
> Where ClientName Like '[a-d]%'
> 
> ...so, it would pull up all clients with names starting with a,b,c, or d.
> 
> But, this isn't working.
> 
> Ideas?
> 
> --
> -----------
> Les Mizzell
> 
> 

--
Barney Boisvert
[EMAIL PROTECTED]
360.319.6145
http://www.barneyb.com/

Got Gmail? I have 100 invites.



~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Find out how CFTicket can increase your company's customer support 
efficiency by 100%
http://www.houseoffusion.com/banners/view.cfm?bannerid=49

Message: http://www.houseoffusion.com/lists.cfm/link=i:4:217181
Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4
Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
Donations & Support: http://www.houseoffusion.com/tiny.cfm/54

Reply via email to