• <tfoot id='NKrso'></tfoot>
      <bdo id='NKrso'></bdo><ul id='NKrso'></ul>

    1. <legend id='NKrso'><style id='NKrso'><dir id='NKrso'><q id='NKrso'></q></dir></style></legend>
      1. <i id='NKrso'><tr id='NKrso'><dt id='NKrso'><q id='NKrso'><span id='NKrso'><b id='NKrso'><form id='NKrso'><ins id='NKrso'></ins><ul id='NKrso'></ul><sub id='NKrso'></sub></form><legend id='NKrso'></legend><bdo id='NKrso'><pre id='NKrso'><center id='NKrso'></center></pre></bdo></b><th id='NKrso'></th></span></q></dt></tr></i><div id='NKrso'><tfoot id='NKrso'></tfoot><dl id='NKrso'><fieldset id='NKrso'></fieldset></dl></div>
      2. <small id='NKrso'></small><noframes id='NKrso'>

        PHP Mysql PDO 绑定变量数量与令牌数量不匹配

        时间:2023-09-20

              <tbody id='J2AP2'></tbody>

              <bdo id='J2AP2'></bdo><ul id='J2AP2'></ul>

              <small id='J2AP2'></small><noframes id='J2AP2'>

                1. <tfoot id='J2AP2'></tfoot>
                2. <i id='J2AP2'><tr id='J2AP2'><dt id='J2AP2'><q id='J2AP2'><span id='J2AP2'><b id='J2AP2'><form id='J2AP2'><ins id='J2AP2'></ins><ul id='J2AP2'></ul><sub id='J2AP2'></sub></form><legend id='J2AP2'></legend><bdo id='J2AP2'><pre id='J2AP2'><center id='J2AP2'></center></pre></bdo></b><th id='J2AP2'></th></span></q></dt></tr></i><div id='J2AP2'><tfoot id='J2AP2'></tfoot><dl id='J2AP2'><fieldset id='J2AP2'></fieldset></dl></div>

                3. <legend id='J2AP2'><style id='J2AP2'><dir id='J2AP2'><q id='J2AP2'></q></dir></style></legend>
                4. 本文介绍了PHP Mysql PDO 绑定变量数量与令牌数量不匹配的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

                  问题描述

                  我环顾四周,但似乎无法找到我的问题的答案.

                  这是我第一次使用 PDO,所以我完全是新手.

                  我将大量数据拆分为 2 个表并希望将它们合并为一个,还有其他方法可以做到这一点,但没有深入探讨为什么我要这样做的复杂原因...

                  我生成了我想从中复制数据的表的记录集

                  构建我的语句

                  循环运行

                  但我收到以下错误

                  SQLSTATE[HY093]: Invalid parameter number: number of bound variables not match of tokens

                  我已经通过并三重检查了我有相同数量的变量,所以为什么令牌不匹配我不知道"就像我说的那样对此很陌生,所以可能错过了专业人士认为显而易见的东西.

                  • 可能值得一提的是,我没有添加到表中的每一列,还有其他列,但我已将它们排除在准备好的语句之外...这是我的代码:

                    //$dbh = new PDO($hostname_Seriously, $DB_USER, $DB_PASSWORD);$dbh = new PDO('mysql:host=localhost;dbname=seriouslysoulful_summers', $username_Seriously, $password_Seriously);$stmt = $dbh->prepare("INSERT INTO records_rec (oldid_rec, firstname_rec,artist_rec,side_rec,bside_rec,label_rec,condition_rec,genere_rec,price_rec,collection_rec,active_rec,info_rec,notes_rec,order_rec,alabelimage_rec,asound_rec_rec,b、featured_rec、format_rec)VALUES (:oldid_rec, :firstname_rec, :artist_rec, :aside_rec, :bside_rec, :label_rec, :condition_rec, :genere_rec, :price_rec, :collection_rec, :active_rec, :info_rec, :notes_rec, :order_image_rec_recasound_rec, bsound_rec, :featured_rec, :format_rec)");$stmt->bindParam(':oldid_rec', $id);$stmt->bindParam(':firstname_rec', $firstname);$stmt->bindParam(':artist_rec', $artist);$stmt->bindParam(':aside_rec',$aside);$stmt->bindParam(':bside_rec',$bside);$stmt->bindParam(':label_rec',$label);$stmt->bindParam(':condition_rec',$condition);$stmt->bindParam(':genere_rec',$genere);$stmt->bindParam(':price_rec',$price);$stmt->bindParam(':collection_rec',$collection);$stmt->bindParam(':active_rec',$active);$stmt->bindParam(':info_rec',$info);$stmt->bindParam(':notes_rec',$notes);$stmt->bindParam(':order_rec',$order);$stmt->bindParam(':alabelimage_rec',$alabel);$stmt->bindParam(':blabelimage_rec',$blabel);$stmt->bindParam(':asound_rec',$asound);$stmt->bindParam(':bsound_rec',$bsound);$stmt->bindParam(':featured_rec',$featured);$stmt->bindParam(':format_rec',$format);$reccount = 0;//做{$id = $row_rs_original['id_prod'];$名字=mysql_real_escape_string($row_rs_original['firstname_prod']);$artist = mysql_real_escape_string($row_rs_original['artist_prod']);$aside = mysql_real_escape_string($row_rs_original['a_side_prod']);$bside = mysql_real_escape_string($row_rs_original['b_side_prod']);$label = mysql_real_escape_string($row_rs_original['label_prod']);$condition = mysql_real_escape_string($row_rs_original['condition_prod']);$genere = $row_rs_original['genre_prod'];$price = $row_rs_original['price_prod'];$collection = mysql_real_escape_string($row_rs_original['collection_prod']);$active = $row_rs_original['active_prod'];$info = mysql_real_escape_string($row_rs_original['info_prod']);$notes = mysql_real_escape_string($row_rs_original['notes_prod']);$order = $row_rs_original['order_prod'];$alabel = mysql_real_escape_string($row_rs_original['labelimage_A_prod']);$blabel = mysql_real_escape_string($row_rs_original['labelimage_B_prod']);$asound = mysql_real_escape_string($row_rs_original['soundfile_A_prod']);$bsound = mysql_real_escape_string($row_rs_original['soundfile_B_prod']);$featured = $row_rs_original['featured_prod'];$format = $row_rs_original['format_prod'];$stmt->execute();$reccount = $reccount +1;/

                  <legend id='fF4b5'><style id='fF4b5'><dir id='fF4b5'><q id='fF4b5'></q></dir></style></legend>

                5. <tfoot id='fF4b5'></tfoot>

                    <tbody id='fF4b5'></tbody>

                  <small id='fF4b5'></small><noframes id='fF4b5'>

                        <bdo id='fF4b5'></bdo><ul id='fF4b5'></ul>
                        <i id='fF4b5'><tr id='fF4b5'><dt id='fF4b5'><q id='fF4b5'><span id='fF4b5'><b id='fF4b5'><form id='fF4b5'><ins id='fF4b5'></ins><ul id='fF4b5'></ul><sub id='fF4b5'></sub></form><legend id='fF4b5'></legend><bdo id='fF4b5'><pre id='fF4b5'><center id='fF4b5'></center></pre></bdo></b><th id='fF4b5'></th></span></q></dt></tr></i><div id='fF4b5'><tfoot id='fF4b5'></tfoot><dl id='fF4b5'><fieldset id='fF4b5'></fieldset></dl></div>