Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> comp.databases.theory -> pattern matching in mysql

pattern matching in mysql

From: abracad <abracad_1999_at_yahoo.com>
Date: 17 Apr 2004 12:35:13 -0700
Message-ID: <e14ddf84.0404171135.54f61f52@posting.google.com>


I have a table, location, of place names eg

place



London
Hong Kong
New York

and wish to search for any places in a user-entered search string eg "London Hong Kong"

In Access the query
  SELECT * FROM location
  WHERE 'London Hong Kong' LIKE '*'&place&'*' returns both Hong Kong and London

But in MySQL nothing is returned, even replacing the MS-specific * with %

How is this achieved in MySQL?

Thanks Received on Sat Apr 17 2004 - 14:35:13 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US