A small correction:  if you want "Jo" to match John or LittleJohn, you need
to do:
SELECT * FROM customers WHERE name LIKE "%Jo%"

Stephen L. Faustino
Senior Software Engineer
SecureLogix Corporation


-----Original Message-----
From: Craig Atkins [mailto:[EMAIL PROTECTED]]
Sent: Thursday, January 18, 2001 9:13 AM
To: '[EMAIL PROTECTED]'
Subject: How To Generate The SELECT statement I need


Hi,
I need to generate a select statement that has a comparison in it.
I have checked the FAQ to no avail.
I want to write something like this:
SELECT * FROM customers WHERE name =~ 'Jo'
 
which uses the =~ comparison (used in Perl) to return any records that
contain the letters 'Jo', which could mean "John" or "LittleJohn"
 
How can I do this in MySQL?
How can I make it case sensitive or insensitive.
 
Thank You For Your Help,
 
Craig Atkins


*********************************************************************
This e-mail and its contents are confidential and are for the 
use of the intended recipient only. If you are not the 
intended recipient, please notify the sender immediately. 
The opinions, statements and thoughts expressed in this
email are only those of the individual sender.
*********************************************************************

---------------------------------------------------------------------
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/           (the list archive)

To request this thread, e-mail <[EMAIL PROTECTED]>
To unsubscribe, e-mail <[EMAIL PROTECTED]>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php

Reply via email to