Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:114223 Return-Path: Delivered-To: mailing list internals@lists.php.net Received: (qmail 64515 invoked from network); 28 Apr 2021 01:15:32 -0000 Received: from unknown (HELO php-smtp4.php.net) (45.112.84.5) by pb1.pair.com with SMTP; 28 Apr 2021 01:15:32 -0000 Received: from php-smtp4.php.net (localhost [127.0.0.1]) by php-smtp4.php.net (Postfix) with ESMTP id B52BB1804CC for ; Tue, 27 Apr 2021 18:19:55 -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=-1.2 required=5.0 tests=BAYES_00,HTML_IMAGE_ONLY_28, 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 forward106o.mail.yandex.net (forward106o.mail.yandex.net [37.140.190.187]) (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 ; Tue, 27 Apr 2021 18:19:54 -0700 (PDT) Received: from iva8-1949f72c19b3.qloud-c.yandex.net (iva8-1949f72c19b3.qloud-c.yandex.net [IPv6:2a02:6b8:c0c:1092:0:640:1949:f72c]) by forward106o.mail.yandex.net (Yandex) with ESMTP id 606405060919 for ; Wed, 28 Apr 2021 04:19:52 +0300 (MSK) Received: from iva4-b3ebd202b141.qloud-c.yandex.net (iva4-b3ebd202b141.qloud-c.yandex.net [2a02:6b8:c0c:4e8e:0:640:b3eb:d202]) by iva8-1949f72c19b3.qloud-c.yandex.net (mxback/Yandex) with ESMTP id s1mI1oFMll-JqIiRDFj; Wed, 28 Apr 2021 04:19:52 +0300 Authentication-Results: iva8-1949f72c19b3.qloud-c.yandex.net; dkim=pass Received: by iva4-b3ebd202b141.qloud-c.yandex.net (smtp/Yandex) with ESMTPSA id UHAYtY7MhV-JpKeEYZY; Wed, 28 Apr 2021 04:19:51 +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 l2so8916903wrm.9 for ; Tue, 27 Apr 2021 18:19:51 -0700 (PDT) X-Gm-Message-State: AOAM532VklopqOXH7LYBk835sF7cYVQVF4RtTsxRVsKc0oFHR3ViiJHP Fh002r0SizlLQ38pLUfYoppydChtaY0zpwdVQ6U= X-Google-Smtp-Source: ABdhPJxE666N9Ym8QW/Mf7Wyeu2sE3Yizhf9x9icj89wULQhhL5ymz3mzIErr53rZLmipkGxP6E0YbWz9vLJAAitAoc= X-Received: by 2002:adf:ce04:: with SMTP id p4mr5090266wrn.115.1619572791143; Tue, 27 Apr 2021 18:19:51 -0700 (PDT) MIME-Version: 1.0 References: <59966331-f58b-a049-a2ce-fe3d4a4e5524@greg0ire.fr> <56F8FD1D-2532-4714-A03E-40BE16D4A416@gmail.com> In-Reply-To: <56F8FD1D-2532-4714-A03E-40BE16D4A416@gmail.com> Date: Tue, 27 Apr 2021 18:19:40 -0700 X-Gmail-Original-Message-ID: Message-ID: To: Gabriel O Cc: =?UTF-8?Q?Gr=C3=A9goire_PARIS?= , internals@lists.php.net Content-Type: multipart/alternative; boundary="000000000000e7718c05c0fe2c72" Subject: Re: [PHP-DEV] RFC: mysqli::in_transaction From: morozov@tut.by (Sergei Morozov) --000000000000e7718c05c0fe2c72 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Hi, There is the SQLGetConnectAttr method and the SQL_ATTR_AUTOCOMMIT attribute (part of the ISO 92 standard) which should allow detecting the transaction state at the driver level. This API used by the SQL Server extensions (to manage the transaction) and it also seems to be available for Oracle and IBM DB2 drivers as well. I'd like to start with the mysqli driver specifically because: 1. MySQL is one of the DB platforms that doesn't support in transactions= . 2. It's much more widely used with PHP than Oracle. We can attempt to implement this functionality in different DB extensions independently since they don't depend on each other. On Mon, Apr 26, 2021 at 1:11 AM Gabriel O wrote: > What about OCI8 driver? That=E2=80=99s also included in core. > > Also a sidermark: SQLSrv and IBMDB2 are not part of core, but situation > should be checked in those as well, since they are supported in DBA tooL > > Powered by *Mailbutler > *, > the email extension that does it all > --=20 Sergei Morozov --000000000000e7718c05c0fe2c72--