| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
| |
Closes GH-6766
|
| |
|
| |
|
|
|
|
| |
Closes GH-6756.
|
|
|
|
|
|
| |
If the ZEROFILL flag is set for a field, do not convert it into
an integer (text protocol) or convert it explicitly into a padded
string (binary protocol).
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* allow the user to specify a folder where files that can be sent
via LOAD DATA LOCAL can exist
* add mysqli.local_infile_directory for mysqli
(ignored if mysqli.allow_local_infile is enabled)
* add PDO::MYSQL_ATTR_LOCAL_INFILE_DIRECTORY for pdo_mysql
(ignored if PDO::MYSQL_ATTR_LOCAL_INFILE is enabled)
* add related tests
* fixes for building with libmysql 8.x
* small improvement in existing tests
* update php.ini-[development|production] files
Closes GH-6448.
Co-authored-by: Nikita Popov <nikic@php.net>
|
|
|
|
| |
Closes GH-6617
|
| |
|
|
|
|
|
|
|
| |
We're starting to see a mix between uses of zend_bool and bool.
Replace all usages with the standard bool type everywhere.
Of course, zend_bool is retained as an alias.
|
|
|
|
| |
Closes GH-6547
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|
|
| |
This includes begin(), commit(), rollBack(), and inTransaction()
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Instead of requiring the type to be determined in advance by the
describer function and then requiring get_col to return a buffer
of appropriate type, allow get_col to return an arbitrary zval.
See UPGRADING.INTERNALS for a more detailed description of the
change.
This makes the result fetching simpler, more efficient and more
flexible. The general possibility already existed via the special
PDO_PARAM_ZVAL type, but the usage was very inconvenient and/or
inefficient. Now it's possible to easily implement behavior like
"return int if it fits, otherwise string" and to avoid any kind
of complex management of temporary buffers.
This also fixes bug #40913 (our second highest voted bug of all
time, for some reason). PARAM_LOB result bindings will now
consistently return a stream resource, independently of the used
database driver.
I've tried my best to update all PDO drivers for this change, but
some of the changes may be broken, as I cannot test or even build
some of these drivers (in particular PDO dblib and PDO oci).
Fixes are appreciated -- a working CI setup would be even more
appreciated ;)
|
|
|
|
|
|
|
| |
This tests that mysqli and pdo_mysql build against libmysqlclient,
and that tests pass for pdo_mysql. mysqli has too many test failures.
This is not an officially supported configuration.
|
| |
|
|\
| |
| |
| |
| | |
* PHP-8.0:
PDO MySQL: Handle boolean parameter binding with libmysql
|
| |
| |
| |
| | |
Previously boolean parameters were simply silently ignored...
|
| |
| |
| |
| | |
mysqlnd expects this to be an unsigned int, not a bool.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Previously, PDO MySQL only fetched data as native int/float if
native prepared statements were used. This patch updates PDO to
have the same behavior for emulated prepared statements, and thus
removes the largest remaining discrepancy between these two modes.
Note that PDO already has a ATTR_STRINGIFY_FETCHES option to control
whether native types are desired or not. The previous output can
be restored by enabling this option.
Most of the tests make use of that option, because this allows the
tests to work under libmysqlclient as well, which currently always
returns string results (independently of whether native or emulated
PS are used).
|
|\ \
| |/
| |
| |
| | |
* PHP-8.0:
PDO MySQL: Use mysqlnd column names
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
mysqlnd already creates interned zend_strings for us, so let's
make use of them.
This also required updating the PDO case changing code to work
with potentially shared strings. For the lowercasing, use the
optimized zend_string_tolower() implementation.
|
| |
| |
| |
| |
| | |
PARAM_ZVAL with a STR result should be treated the same way as
PARAM_STR in this regard.
|
|\ \
| |/
| |
| |
| | |
* PHP-8.0:
Drop pdo_mysql_prepare_load_data.phpt
|
| |\
| | |
| | |
| | |
| | | |
* PHP-7.4:
Drop pdo_mysql_prepare_load_data.phpt
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Like the test title and some comments in this test describe, this test
was supposed to have `::prepare()` failing because `LOAD DATA INFILE`
would not be supported as prepared statement, and then the test checks
whether follow-up queries would succeed. However, `LOAD DATA INFILE`
is supported for prepared statements at least on Windows with mysqlnd,
so the test does no longer test what it is supposed to do. Therefore,
we drop it.
Closes GH-6509.
|
| | |
| | |
| | |
| | |
| | | |
This API already doesn't match libmysqlclient, so we may as well
use the zmm.
|
| | |
| | |
| | |
| | |
| | | |
Rather than storing char* + size_t, use a zend_string*. Also
avoid various copies of the query string.
|
|\ \ \
| |/ /
| | |
| | |
| | | |
* PHP-8.0:
Fixed bug #79132
|
| | |
| | |
| | |
| | |
| | |
| | | |
Following cmb's suggestion and replacing the counter with a check
against the bound_params HT, which ensures that both cannot go
out of sync.
|
|\ \ \
| |/ /
| | |
| | |
| | |
| | | |
* PHP-8.0:
PDO MySQL: Fix nextRowset() on libmysqlclient with native PS
PDO MySQL: Don't skip two LOCAL_INFILE tests with libmysqlclient
|
| | |
| | |
| | |
| | |
| | |
| | | |
The logic after next_result should match the one after execute.
This was the case for mysqlnd but not libmysqlclient, which used
the non-PS logic.
|
| | | |
|
|\ \ \
| |/ /
| | |
| | |
| | | |
* PHP-8.0:
PDO MySQL: Unskip bug_41125.phpt
|
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
This test was always skipped (leftover debug statement?)
Contrary to the comments in the test and the test expectation,
this actually works fine.
|
|\ \ \
| |/ /
| | |
| | |
| | | |
* PHP-8.0:
Fixed bug #67004
|
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Repeated execute() with native PS failed to release the previous
result set on libmysqlclient.
Move freeing the result set into a common location.
|
|\ \ \
| |/ /
| | |
| | |
| | |
| | | |
* PHP-8.0:
PDO MySQL: Use stmt_next_result with libmysqlclient as well
PDO MySQL: Fix libmysql option test
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
libmysqlclient added this function in version 5.5, which happens
to be the minimum we support. If we have a prepared statement,
we should use it on both mysqlnd and libmysqlclient, even if the
handling afterwards is different.
This fixes error handling with native prepared statements.
|
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
The fact that getAttribute() fails for various libmysqlclient-only
options is a known issue, and the test was taking that into account.
However, the change of the default error mode broke the handling.
We need to handle the exceptions now.
|
|\ \ \
| |/ /
| | |
| | |
| | | |
* PHP-8.0:
Fixed bug #62889
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Our minimum libmysqlclient version requirement is high enough
that we don't need to check for MYSQL_OPT_LOCAL_INFILE support.
However, the mysql_get_option() function seems to only be available
since 5.7 (though it's really hard to find any definitie information
on when MySQL introduced certain functions or changes...) so we
need to store the value of the flag locally to make it available
through getAttribute().
|
|\ \ \
| |/ /
| | |
| | |
| | | |
* PHP-8.0:
PDO MySQL: Fix leak with libmysqlclient and multiple rowsets
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
stmt->column_count gets reset before the next_rowset handler is
invoked, so we need to fetch the value from the result set instead.
Arguably PDO should be separating the destruction of the previous
result set and the switch to the next result set more cleanly...
|
|\ \ \
| |/ /
| | |
| | |
| | | |
* PHP-8.0:
Fix test cases for MariaDB
|