Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:114016 Return-Path: Delivered-To: mailing list internals@lists.php.net Received: (qmail 19470 invoked from network); 10 Apr 2021 17:13:24 -0000 Received: from unknown (HELO php-smtp4.php.net) (45.112.84.5) by pb1.pair.com with SMTP; 10 Apr 2021 17:13:24 -0000 Received: from php-smtp4.php.net (localhost [127.0.0.1]) by php-smtp4.php.net (Postfix) with ESMTP id 4B8691804BD for ; Sat, 10 Apr 2021 10:13:28 -0700 (PDT) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on php-smtp4.php.net X-Spam-Level: X-Spam-Status: No, score=-2.6 required=5.0 tests=BAYES_00,HTML_MESSAGE, RCVD_IN_DNSWL_LOW,RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_PASS autolearn=no autolearn_force=no version=3.4.2 X-Spam-Virus: No X-Envelope-From: Received: from forward102o.mail.yandex.net (forward102o.mail.yandex.net [37.140.190.182]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by php-smtp4.php.net (Postfix) with ESMTPS for ; Sat, 10 Apr 2021 10:13:26 -0700 (PDT) Received: from iva7-eacae0ae1191.qloud-c.yandex.net (iva7-eacae0ae1191.qloud-c.yandex.net [IPv6:2a02:6b8:c0c:322a:0:640:eaca:e0ae]) by forward102o.mail.yandex.net (Yandex) with ESMTP id E0457668187E for ; Sat, 10 Apr 2021 20:13:24 +0300 (MSK) Received: from iva6-2d18925256a6.qloud-c.yandex.net (iva6-2d18925256a6.qloud-c.yandex.net [2a02:6b8:c0c:7594:0:640:2d18:9252]) by iva7-eacae0ae1191.qloud-c.yandex.net (mxback/Yandex) with ESMTP id Mp5dzpUYYQ-DOIG25Ht; Sat, 10 Apr 2021 20:13:24 +0300 Authentication-Results: iva7-eacae0ae1191.qloud-c.yandex.net; dkim=pass Received: by iva6-2d18925256a6.qloud-c.yandex.net (smtp/Yandex) with ESMTPSA id U6eeksodNP-DOKqFQjl; Sat, 10 Apr 2021 20:13:24 +0300 (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) (Client certificate not present) Received: by mail-wr1-f50.google.com with SMTP id x15so8673260wrq.3 for ; Sat, 10 Apr 2021 10:13:24 -0700 (PDT) X-Gm-Message-State: AOAM530vqblAxUuQV02fb7R+nQ4yDAyPO4Vtm7Vn0P1ux841EuIkVZ4G 8IsJ/ZiuHxxZc6jmVu5UEE8xyKORjqkk6FC/CBk= X-Google-Smtp-Source: ABdhPJyjY7wHf3vxEhgQyGNZHhtHHYZcDnMUM8cebXi70leJLLnNFoH1X5SPSfOumj9P1hah+IhJz0QxrCxWdvp1FT4= X-Received: by 2002:adf:ecc8:: with SMTP id s8mr3092965wro.169.1618074803539; Sat, 10 Apr 2021 10:13:23 -0700 (PDT) MIME-Version: 1.0 Date: Sat, 10 Apr 2021 10:13:12 -0700 X-Gmail-Original-Message-ID: Message-ID: To: PHP Internals Content-Type: multipart/alternative; boundary="000000000000e2931c05bfa165e7" Subject: Use MySQL syntax only for parsing MySQL statements in PDO From: morozov@tut.by (Sergei Morozov) --000000000000e2931c05bfa165e7 Content-Type: text/plain; charset="UTF-8" Hi Internals, There are bugs #79276 and #80340 where PDO parses valid PostgreSQL statements incorrectly because it uses MySQL grammar for all statements regardless of the underlying platform. I submitted pull request #6410 which enables extensions to opt-in to MySQL-specific syntax (since it's not standard). Currently only `pdo_mysql` uses it. As Christoph Becker suggested, I'm bringing it here for discussion. Technically, it may be a BC break since there may exist PDO-based extensions outside the PHP repository that rely on compatibility with the MySQL syntax. Are there known extensions like this? Would this change be acceptable in one of the next minor releases? Regards, Sergei Morozov --000000000000e2931c05bfa165e7--