Re: Show only user that variable "music"contain "pop"
| From: | Benjamin Trépanier | Date: | Wed, 27 Nov 2002 20:43:17 +0000 |
| Subject: | Re: Show only user that variable "music"contain "pop" | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-126353@lists.php.net to get a copy of this message | ||
$req = MYSQL_QUERY("SELECT id FROM $TBL_NEWS ORDER BY nom LIMIT 0,
$limit_news");
$res = MYSQL_NUM_ROWS($req);
This is my lines... It's not working... :-(
Thanks for your help
Le 27/11/02 15:23, « Support @ Fourthrealm.com » <support@fourthrealm.com> a
écrit :
If you only have one condition, then get rid of the AND in the where statement; Select only the fields that you need, instead of * Like this: SELECT id FROM $TBL_NEWS WHERE music LIKE '%pop%' ORDER BY name Peter At 03:16 PM 11/27/2002 -0500, Benjamin Trépanier wrote:$req = MYSQL_QUERY("SELECT id FROM $TBL_NEWS ORDER BY nom LIMIT 0, $limit_news"); $res = MYSQL_NUM_ROWS($req); This is my lines... It's not working... :-( Thanks for your helpHi, I need information about a simple command... I have a DB (of course...) and I need to show only "ID" that variable "music"contain "pop" I found this example that is suppose to do a similar thing in a msql query... SELECT * FROM $TBL_NEWS WHERE music LIKE '%pop%' AND ORDER BY name So it's not working properly... Thanks for your help Ben -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php- - - - - - - - - - - - - - - - - - - - - Fourth Realm Solutions pbechard@fourthrealm.com http://www.fourthrealm.com Tel: 519-739-1652 - - - - - - - - - - - - - - - - - - - - - -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php