Jump to content
php.lv forumi

Recommended Posts

Posted

Sveiki, vai varat palīdzēt?

kad uzrakstu šadu kodu

$SQL="SELECT * FROM par_mums where lang='lv'";
echo $SQL;
$rez = mysql_db_query ($datubaaze, $SQL ,$db);
while ($row = mysql_fetch_object($rez))
{
echo $row['tema'];
echo $row['saturs'];
echo $row['lang'];
echo "<br />";


echo "<br>";
}

 

tad man lapā rādās

SELECT * FROM par_mums where lang='lv'

Warning: mysql_fetch_object(): supplied argument is not a valid MySQL result resource in C:\wamp\www\CS_NEW\index_www.php on line 61

 

61 rindiņa ir: while ($row = mysql_fetch_object($rez))

Lietoju WAMP 1.7. 3

Posted

No mysql_db_query() manuāļa lapas:

 

Returns a positive MySQL result resource to the query result, or FALSE on error. The function also returns TRUE/FALSE for INSERT/UPDATE/DELETE queries to indicate success/failure.

 

Izmanto mysql_query();

×
×
  • Create New...