コードでエラーが発生しています。これは、コードの column=:variable セクションに何か問題があることを意味していると確信していますが、調べてみたところ、何が問題なのかわかりません。
Fatal error: Uncaught exception 'PDOException' with message 'SQLSTATE[HY093]: Invalid parameter number: number of bound variables does not match number of tokens' in F:\...
コードは次のとおりです (長い最初の行):
$stmt = $dbh->prepare("UPDATE item_list SET quantity=:quantity, new_price=:newprice, image_link=:image_link, market_hash_name=:markethashname, last_update='1000-01-01 00:00:00', is_tradable='TEST', old_price=:oldprice WHERE item_name=:itemname AND (image_link IS NULL OR quantity IS NULL OR new_price IS NULL OR market_hash_name IS NULL OR last_update IS NULL OR is_tradable IS NULL OR old_price IS NULL)");
$sql->bindParam(':quantity', $json2->quantity);
$sql->bindParam(':newprice', $json2->lowest_price);
$sql->bindParam('image_link', $image_link_full);
$sql->bindParam(':markethashname', urlencode($mydata->market_hash_name));
$sql->bindParam(':oldprice', $json2->lowest_price);
$stmt->bindValue(':itemname', $mydata->market_name);
$stmt->execute();
編集: image_link は :image_link である必要がありましたが、同じエラーが発生します
編集 2: 多くの間違いがあり、bindParam の代わりに bindValue を使用して、$sql と $stmt の 2 つの名前を使用していました