This error appears when the query was not executed correctly for some reason.
The most-common reasons may be:
- The connection with MySQL is not working.
- The query is wrong.
It looks like your query isn't wrong, so, you can try to check this:
1. Is "zvena" the table name?
2. Are you really connected to MySQL? The mysql_connect doesn't fail?
3. Are you using the right database?
If none of this helps you, please post your full code here.
Only for advice, i don't know what PHP version that are you using, but mysql_* was deprecated in PHP 5.5.x.
I recommend you to use PDO or a ORM like Doctrine.
Can someone help me i get following error : mysql_fetch_object(): supplied argument is not a valid MySQL result
$combo_sql=mysql_query("SELECT id, name FROM zvena where id =$id") or die(mysql_error());
echo "<option value='".$currobj->name."'>".$currobj->name."</option>";