| Age | Commit message (Collapse) | Author | Files | Lines |
|
Affected_Rows() always returns false on PHP 8.1, because the
'pgsql result' resource has been replaced by the PgSql\Result class [1].
Changes to original contribution:
* Adjust PHPDoc for ADODB_postgres64::$_resultid
* Fix one more occurrence in the postgres7 driver
Fixes #833
[1]: https://www.php.net/manual/en/class.pgsql-result.php
Co-authored-by: Damien Regad <dregad@mantisbt.org>
(cherry picked from commit e3287d6be5545634a6ccbf868919028991a68791)
|
|
Following up on #767, per @Unifex's suggestion [1], removing _fixblobs()
and moving its code into new _prepFields() function.
Additional changes:
- add PHPDoc block
- protected attribute
- remove return type - not really useful as in most cases success is
evaluated by checking $this->fields !== false
- fixed a couple remaining occurrences of is_array() checks
- coding guidelines
[1]: https://github.com/ADOdb/ADOdb/pull/760#issuecomment-961564909
|
|
The call to pg_fetch_array() returns false in all cases where we would
not need or want to potentially _fixblobs() and return true. A straight
up boolean check is all that is needed here, no need for in_array().
Tracking through _fixblobs() is called in a number of places and how its
result is checked was repeated in every case. The checks were moved into
the function, which was updated to return a boolean should we want to
check that.
It was also noted that in every case the setting of $this->fields was
identical as well so new _prepfields() method was added which sets
$this->fields and calls _fixblobs().
All instances of _fixblobs() were replaced with _prepfields() and the
pg_fetch_array() call deleted.
Fixes #767 (replacing #760)
|
|
|
|
- public visibility
- camelCase
- change $owner default from false to ''
- add $associative param where missing
- PHPDoc updates
|
|
Method is not used anywhere.
|
|
|
|
Try to do it right this time...
# Conflicts:
# adodb-memcache.lib.inc.php
Fixes #751
|
|
Fixes #751
|
|
The conflicts resolution applied when merging the Standardized file
headers (commit e9dcce3df24912ad869d0193f0b419f2309101fc) was seriously
messed up, actually overwriting a number of changes in the master
branch.
Rather than trying to go and fix things one by one which has a high risk
of messing things further, it's easier to redo the merge from a clean
slate, so this commit reverts the following:
- "Merge branch 'hotfix/5.21' Standardized file headers",
e9dcce3df24912ad869d0193f0b419f2309101fc
- "Merge tag 'v5.21.1'",
5f437df3104159d5d659f60e31bef8d33c34995f
- "Reset version to 5.22.0-dev"
af9234a525c3255af051a330164486d73be4c63a
- "Fix incorrect resolution of merge conflicts"
a6733f61b0165b366c8d2c70d9af82edc3881951.
- "Fix syntax error in toexport.inc.php"
20b01e83cb61b6b2460f64c7d1277c5f4cc28574.
Fixes #751
|
|
|
|
|
|
Simplify the code in mysqli and postgres7 drivers, and get rid of
unnecessary `@` error suppresion.
|
|
On mysqli, PHP 8 throws an 'Uncaught TypeError: method_exists():
Argument 1 ($object_or_class) must be of type object|string, bool
given'. Checking that _connectionID is set fixes the problem.
A similar issue was found and fixed with the postgres7 driver as well.
Note that fixing the legacy mysql driver is not necessary, as the driver
has been removed in PHP 7, and the error suppression operator should do
the job on PHP 5.
Fixes #686
|
|
|
|
|
|
|
|
|
|
|
|
I messed up the merge at c350c007ed585a4da4dc8c62ae7954cfe13b621f. Not
sure what I did or how, but the changes from the hotfix branch got lost.
Redoing the merge to fix the problem.
|
|
The `SelectLimit` function has a potential SQL injection vulnerability
through the use of the `nrows` and `offset` parameters which are not
forced to integers.
This is a follow-up on #311, and fixes all remaining drivers that do not
use ADOConnection::SelectLimit().
Fixes #401
Signed-off-by: Damien Regad <dregad@mantisbt.org>
Original commits squashed, message reworded. Fixed whitespace.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Fixes #171
|
|
|
|
|
|
|
|
- running SED script
- manual adjustments for files not processed by regex
|
|
Currently, this method only exists in postgres7, oci8 and derived
drivers. Moving it to the base class will enable reuse by other drivers
that need the functionality.
|
|
- Avoid code duplication
- optimize ADORecordSet_assoc_postgres7::_updatefields()
|
|
|
|
|
|
Use proper PostgreSQL function names rather than legacy aliases that
arent documented anymore. This should continue to work back to PHP v4.2
still, and also works with HHVM.
Signed-off-by: Damien Regad <dregad@mantisbt.org>
|
|
When calling MetaColumns with schema.table, the driver triggers a
'Warning: sprintf(): Too few arguments' because the metaColumnsSQL1
statement contains one more parameter in 7 compared to the 6.4 version.
Resolved by adding a new protected _generateMetaColumnsSQL() method to
handle the preparation of the appropriate SQL statement, and overriding
it in the postgres7 driver.
http://phplens.com/lens/lensforum/msgs.php?id=19481
|
|
|
|
The original SQL from William Kolodny [William.Kolodny#gt-t.net] was
very complex with multiple sub-select statements.
Through use of regexp_replace() instead of split_part(), we now have
only a single subquery.
Removed obsolete comment.
|
|
|
|
|
|
|
|
|