How to query using mysqli prepared statements where 2 columns equal different values?
I am trying to query a database basically so it looks like this:
$stmt5 = $DBH->prepare("SELECT id FROM numbers WHERE value1 = ? value2 = ?");
$stmt5->bind_param("ss",$value1,$value2);
But i keep receiving "Call to a member function bind_param 开发者_JS百科on non-object" how can i do this?
You are missing an AND try this
$DBH->prepare("SELECT id FROM numbers WHERE value1 = ? AND value2 = ?")
精彩评论