Jump to content

Searching the contents of just one field?


woolyg

Recommended Posts

Hi,

 

I'm trying to put together a script that will search the contents of just one field, specified by its row ID.

 

I'm using:

 

SELECT mailing_list,               
MATCH(mailing_list)  
               AGAINST ('$emailaddress,' IN BOOLEAN MODE) AS score FROM table
               WHERE MATCH(mailing_list)  
              AGAINST ('$emailaddress,' IN BOOLEAN MODE) 
              AND row_id='$row_id'

 

So from the code above, I wanna search the field 'mailing_list' where the row_id is of a certain value. But the result is returning information from other rows - it seems to be ignoring the AND row_id=$row_id bit..

 

Is there a way to use the search string above to have it search just the ONE field, in the ONE row?

 

All help appreciated,

woolyg.

Link to comment
https://forums.phpfreaks.com/topic/70314-searching-the-contents-of-just-one-field/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.