title: Oddly some times value float value returns 0
body: <p>I'm a beginner at php trying to solve usage of PDO in PHP...</p>
  
  <p>I have a PDO query: usually it returns correct value (integer 1) but sometimes i don't know how, it returns (0 or null) it happens randomly and no idea why.</p>
  
  <p>Server windows based. Double checked database.. all Multiplier values (integer 1)</p>
  
  <pre><code>$q = $db-&gt;prepare("SELECT Multiplier,Balance FROM buoys WHERE ID=:ID");
  
  $aID = $_POST['ID'];
  $aFishValue = (float)0.4;
  
  $q-&gt;execute(array(':ID' =&gt; $aID));
  $res = $q-&gt;fetch(PDO::FETCH_OBJ); 
  
  $aEvent = (integer)$res-&gt;Multiplier; // Some How this value some times returns 0 but all values in database integer 1.
  $aBuoyBalance = (float)$res-&gt;Balance;
  
  $aFishValue = (float)$aFishValue * (float)$aEvent;
  </code></pre>
  
  <p>Most of the time <code>$aFishValue</code> returns correctly but some times returns null. I'm totally stuck and googled for hours... No idea what to do next. </p>