title: Php mysqli_query returns error but phpmyadmin works
body: <p>I know there are other questions like mine here but nothing seems to help me since in my case is a lot of different. Basically I a big algoirthm which computes stuff and puts SQL strings into an array and then I take that array and query it one by one in a for loop. I have done that in the past for more complicated stuff as well. However this time, which is not different than the other times I am trying to execute my query and it returns false. When I print it out so check if my variables are correct and run it through phpmyadmin it works perfectly no problems there. Please if someone is way more experienced can spot what is the error because I spent 1 day and I am hopeless. May be a silly one but like I said there is no different than the other times and I have done the same technique many times(big computation, make sql strings and then execute them oneby one)</p>
  
  <pre><code>mysqli_query($conn,$sqls[0]);
  echo $sqls[0];
  echo "mysqli error: " . mysqli_error($conn) . "&lt;br&gt;";
  </code></pre>
  
  <p>made as simple as possible to check for error. $sqls is basically the array.</p>
  
  <p>and I get this :</p>
  
  <pre><code>INSERT INTO driverPaySheets (`driverid`,`missionRef`,`days`,`nights`,`rules`,`dateFrom`,`dateTill`) VALUES('4','ed5d68791186038421ab3b7df98df925','1','0.5','1','1490068800','1490103000')
  </code></pre>
  
  <blockquote>
    <p>mysqli error: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '
    ' at line 1</p>
  </blockquote>
  
  <p>which doesnt even help me because it doesnt even give me the error.</p>