Advertisement
Guest User

Untitled

a guest
Apr 24th, 2014
56
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.85 KB | None | 0 0
  1. $insertQuery = "INSERT INTO `Some_Database`
  2. (`time`, `timestamp`, `price_btc`, `volume_btc`, `market`, `price_usd`, `difficulty`)
  3. VALUES (:current_time, :current_timestamp, :price_btc, :volume_btc, :doge_market, :price_usd, :difficulty)";
  4. $insertStmt = $database->prepare($insertQuery);
  5. $insertStmt->bindParam(":current_timestamp", $currenttimestamp);
  6. $insertStmt->bindParam(":price_btc", $priceBTC);
  7. $insertStmt->bindParam(":volume_btc", $volumeBTC);
  8. $insertStmt->bindParam(":price_usd", $priceUSD);
  9. $insertStmt->bindParam(":difficulty", $difficulty);
  10. $insertStmt->execute(Array(":current_time" => $currentTime, ":doge_market" => $dogeMarket)); // Note: this is line 101
  11.  
  12. Warning: PDOStatement::execute() [pdostatement.execute]: SQLSTATE[HY093]:
  13. Invalid parameter number:
  14. number of bound variables does not match number of tokens in somepath/somefile.php on line 101
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement