Re: Thanks but problem Again! (MySQL & PHP database script PLEASE)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



> Thank you for two of you. Im amazed how quick the replys were. Very
> pleased.
> When I simply inserted the PHP sentense, it worked.
> But as I turned off register_globals,
> and changed as Matthew suggested, it looked like this:
>
> Warning: mysql_num_rows(): supplied argument is not a valid MySQL result
> resource in c:\apache\htdocs\momatlib\gen_search1.php on line 49
> Records Available
>
> Warning: mysql_fetch_array(): supplied argument is not a valid MySQL
> result
> resource in c:\apache\htdocs\momatlib\gen_search1.php on line 52
> BTW
>
> When I added this  (or die("Bad query: ".mysql_error()); ) in this part
> ($result = mysql_query...)
>
> Ive got this.
>
> Bad query: You have an error in your SQL syntax near 'and Tit like and Aut
> like and Auty like ' at line 4
>
>

Ramil and Dan are probably correct. There's something not right with your
query string.

A good test to try is to run the query from the mysql prompt and
substitute the vars with actual values and see if it returns correctly.

-- 
--Matthew Sims
--<http://killermookie.org>

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


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux