Hello!!

Your right!!

don't use = on the like part...I don't know what I was thinking!!!

Anyway here is the code right from my search page...

include("./navbar2.php");
        $nav = new navbar;
        $nav->numrowsperpage = 30;
        $sql = "SELECT Print_Name, Art_Job_Number, Size, Item_Number FROM 
Table1 WHERE Print_Name LIKE '%$Print_Name%' ORDER BY $or $place";
        $result = $nav->execute($sql, $db, "mysql");
        $rows = mysql_num_rows($result);
        for ($y = 0; $y < $rows; $y++){
        $data = mysql_fetch_object($result);

That should do it!!

Dan


On Thursday, April 25, 2002, at 09:23 AM, [EMAIL PROTECTED] wrote:

> The query should read as below, without the = after the LIKE:
>
> $query = "SELECT uid, id, image, iname, quantity, type FROM
> {$config["prefix"]}_shop WHERE iname LIKE '%$shopsearch% ORDER BY
> iname'";
>
> HTH
>
> Maureen
>
>
> Jennifer Downey <[EMAIL PROTECTED]> said:
>
>> Hi all,
>>
>> I have been trying to build a search script for my site that deals 
>> with only
>> one table in my db.
>> As Julie Meloni pointed out look in the MySQL manual for LIKE clauses I
>> can't seem to locate that clause in ether
>> manual.
>> Dan Brunner gave me this to go on:
>>
>> $query = "SELECT uid, id, image, iname, quantity, type FROM
>> {$config["prefix"]}_shop WHERE  iname  LIKE = '%$shopsearch% ORDER BY
>> iname'";
>> $ret = mysql_query($query);
>> while(list($quantity)=mysql_fetch_row($ret))
>>
>> But I can't seem to get this to work. I have never worked with LIKE 
>> before
>> and would appreciate any help on this.
>>
>> Thanks Julie and Dan for your time and effort.
>>
>> Thanks all for your time and help
>> Jennifer
>>
>>
>> --
>> The sleeper has awaken
>>
>>
>> ---
>> Outgoing mail is certified Virus Free.
>> Checked by AVG anti-virus system (http://www.grisoft.com).
>> Version: 6.0.351 / Virus Database: 197 - Release Date: 4/19/2002
>>
>>
>>
>> --
>> PHP Database Mailing List (http://www.php.net/)
>> To unsubscribe, visit: http://www.php.net/unsub.php
>>
>
>
>
> --
>
>
>
>
> --
> PHP Database Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>


-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to