Bluehost.com Web Hosting $6.95

Can't find the start

This is a discussion on Can't find the start within the MySQL Database forums, part of the Database Forums category; Hi guys, I've a query built in this way $query = "SELECT * FROM foo WHERE bar REGEXP '$item' ORDER ...


Go Back   Usenet Forums > Database Forums > MySQL Database

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 02-03-2007
zano®
 
Posts: n/a
Default Can't find the start

Hi guys,

I've a query built in this way

$query = "SELECT * FROM foo WHERE bar REGEXP '$item' ORDER BY data DESC
LIMIT 0,100";
$result = mysql_query($query);

It works correctly only if $item is not equal to a value in the DB.
E.G. I've column with the string patrol
If $item is different from patrol which means atrol trol atr and so on,
the query returns all the occurences of patrol.
If $item is patrol no occurrence is found.
I've tried with LIKE, with '%$item%' but without any success.

Any idea?


--
Esti Qatzi
http://zelohim.it upd 20.01.07 ubuntu user #4898

Il Fattucchiero puņ allacciarsi le scarpe con i piedi.


Reply With Quote
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are Off
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On




All times are GMT +1. The time now is 05:37 AM.


Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO 3.0.0