Details
-
Bug
-
Status: Resolved
-
Major
-
Resolution: Fixed
-
2.6
-
None
-
None
-
CentOS
-
Docs Required
Description
Using odbc_connect returns all column values, but with PDO only the 1st one – all the rest are null.
Reproduced on CentOS.
- Start a server node with Ignite CPP
- Run odbc-example (which will create two tables)
- Run a simple PHP script
<?php try { echo PHP_EOL,PHP_EOL,"# Using PDO",PHP_EOL; $dbh = new PDO('odbc:ApacheIgnite'); $dbh->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION); $sql = 'SELECT * FROM "Person".Person'; $data = $dbh->query($sql); foreach($data as $row) { var_export($row); } echo PHP_EOL,PHP_EOL,"# Using odbc_*( ) Functions",PHP_EOL; $conn = odbc_connect('ApacheIgnite','',''); $rs = odbc_exec($conn, $sql); while($row = odbc_fetch_array($rs)) { var_export($row); } } catch (PDOException $e) { print "Error!: " . $e->getMessage() . "\n"; die(); } ?>
Attachments
Attachments
Issue Links
- relates to
-
IGNITE-7362 ODBC: Third party libraries truncate any inserted varlen data to ColumnSize
- Resolved
- links to