|
|
Supplied argument is not a valid in MySQL result resource - Mysql
|
Views : 768
|
|
Tagged in : Mysql
|
|
|
Report This Scrap as Inappropriate We request you to choose the appropriate categroy and subcategory that suits your
objectionable concern about the scrap, So that our team can review and find out whether it violates our Guidelines or the
scrap is not suitable for all viewers.
|
Hi....
You need to check for errors after submitting a query and before you attempt to use the returned result identifier. The proper way to do this is with code similar to the following:
<?php
$result = mysql_query("SELECT * FROM tables_priv");
if (!$result) {
echo mysql_error();
exit;
}
?>
or
<?php
$result = mysql_query("SELECT * FROM tables_priv")
or die("Bad query: " . mysql_error());
?>
|
|
By Nirmala, On - 2008-11-19 |
|
|
|