Try something like this ...

$sql_query = "SELECT newscat_id,newscategory,newscat_status FROM
dvd.news_categories WHERE newscat_id='$newsid' "

 $res = mysql_query( $sql_query) or 
    DIE ("MySQL gave error: " . mysql_errno() . "<br>MySQL Error
String: " . mysql_error()
          . "<br>Query: " . $sql_query);

This should give you a good idea what the error is ..

When ever you are creating new scripts with db queries it is a handy
idea to see what the server is putting our during error conditions.

DTSig
David Tod Sigafoos

On Wed, 26 Sep 2001 18:09:36 +0200, [EMAIL PROTECTED] (Tommy
Nilsson) wrote:

>I got a bit of a problem:
>    $result1 = mysql_query ("SELECT
>newscat_id,newscategory,newscat_status FROM dvd.news_categories WHERE
>newscat_id='$newsid'")
> 
>shouldn't that work?
>Or what is wrong with it?
>Im running apache/mysql om windows XP.


-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

Reply via email to