Skip to content

Conversation

@sharadraju
Copy link
Collaborator

@sharadraju sharadraju commented Jan 5, 2026

This is an improvement from PR #15 based on inputs from @mvorisek and @ndossche and with an added test.

Credited Ashutosh Agrawal and Michael Vorisek.

@sharadraju
Copy link
Collaborator Author

sharadraju commented Jan 5, 2026

@shivammathur is zval_is_true removed in PHP 8.6?

@shivammathur
Copy link
Member

@sharadraju

Yes, please use zend_is_true for 8.6.
Ref: php/php-src#20065

@sharadraju
Copy link
Collaborator Author

@sharadraju

Yes, please use zend_is_true for 8.6. Ref: php/php-src#20065

Thanks @shivammathur for the quick response


$conn = PDOTest::factory();

$stmt = $conn->prepare('SELECT ?, ? FROM DUAL');
Copy link
Collaborator

@mvorisek mvorisek Jan 5, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would like another test with (temporary) table with BOOLEAN type. The expect result is false/true inserted correctly.

Copy link
Collaborator Author

@sharadraju sharadraju Jan 5, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mvorisek BOOLEAN data type columns are supported only from Oracle Database 23ai. Is that what you are referring to?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Adding the BOOLEAN data type gives a warning with Oracle 23ai (and 26ai) client libraries as these libraries have implemented the BOOLEAN data type.

Warning: PDOStatement::fetchAll(): Column 1 data was too large for buffer and was truncated to fit

You can check the failed builds in this PR for the error.

So the pdo_oci driver needs an enhancement to support the Oracle 23ai Client implementation of the BOOLEAN data type.

Co-authored-by: Michael Voříšek <[email protected]>
Copy link
Member

@ndossche ndossche left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Technically looks fine, didn't try running the tests

@sharadraju
Copy link
Collaborator Author

I will be merging this for now. Please see comment #29 (comment) on the BOOLEAN data types.

@sharadraju sharadraju merged commit 4fbdfca into main Jan 6, 2026
54 checks passed
@mvorisek mvorisek deleted the pdo_oci_param_bool_fix branch January 6, 2026 09:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants