How to check if INSERT IGNORE has actually inserted the row from php
<p>I have the following problem,I don't know how to check if my MySql query has actually inserted or ignored the insert from my php code.<br>
This is because as far as I know it always returns true, due to the error preventing of the ignore clause.<br>
A sample of what I have is:  </p>

<pre><code>$addTagSql = "INSERT IGNORE INTO tags (text) 
  VALUES ('$text')";
$resultAddTag = $db -&gt; query($addTagSql);

if(!$resultAddTag) {
  $response["success"] = 0;
}
else{
  $response["success"] = 1;
}  
</code></pre>

<p>Should I just let it break and handle the error?<br>
I couldn't find a good answer, so I'd be glad if you can help me :)</p>