title: Integrity constraint violation: 1452 Cannot add or update a child row: a foreign key constraint fails
body: <p>I am using the Yii framework and having the following Yii error with the database when attempting an insert into a table - I can see that the user with the user_id of '5702157058' exists in my 'myuser' table so not sure why I am getting this error?</p>
  
  <pre><code>&lt;h1&gt;CDbException&lt;/h1&gt;
  &lt;p&gt;CDbCommand failed to execute the SQL statement: SQLSTATE[23000]: Integrity constraint violation:       
  1452 Cannot add or update a child row: a foreign key constraint fails (`mydb`.`organisation_news_read`, 
  CONSTRAINT `FK_organisation_news_read_myuser` FOREIGN KEY (`user_id`) REFERENCES `myuser_`
  (`user_id`) ON DELETE CASCADE ON UPDATE NO ACTION). The SQL statement executed was: 
  INSERT INTO `organisation_news_read` (`news_id`, `user_id`) VALUES (:yp0, :yp1). 
  Bound with :yp0=287, :yp1='5702157058'
  </code></pre>