Let's say I have an update button on the bank.
$query = mysql_query("UPDATE $tabela set algo='$algo' WHERE id=1);
if ($query) {
echo "sucesso";
} else {
echo 'falha';
}
To check if the query was successfully registered in the database (if there was no connection error (eg the connection crashed) or if there was an error in the update) I do the above procedure?