ignite-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Roman Shtykh (JIRA)" <j...@apache.org>
Subject [jira] [Comment Edited] (IGNITE-9897) Quering with PDO returns null for all column values except the 1st one
Date Tue, 30 Oct 2018 14:55:00 GMT

    [ https://issues.apache.org/jira/browse/IGNITE-9897?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16668818#comment-16668818
] 

Roman Shtykh edited comment on IGNITE-9897 at 10/30/18 2:54 PM:
----------------------------------------------------------------

[~isapego]

Array
 (
     [ORGID] => 2
     [0] => 2
     [FIRSTNAME] =>
     [1] => }}{{

...

All the rest are empty columns.

I am using unixODBC

{{$ odbcinst -j}}
 {{unixODBC 2.3.1}}
 {{DRIVERS............: /etc/odbcinst.ini}}
 {{SYSTEM DATA SOURCES: /etc/odbc.ini}}
 {{FILE DATA SOURCES..: /etc/ODBCDataSources}}
 {{USER DATA SOURCES..: /home/xxx/.odbc.ini}}
 {{SQLULEN Size.......: 8}}
 {{SQLLEN Size........: 8}}
 {{SQLSETPOSIROW Size.: 8}}

 

{{$ php --version}}
 {{PHP 5.4.16 (cli)}}

 


was (Author: roman_s):
[~isapego] 

{{Array}}
{{(}}
{{    [ORGID] => 2}}
{{    [0] => 2}}
{{    [FIRSTNAME] => }}
{{    [1] => }}{{}}

...

All the rest are empty columns.

I am using unixODBC

{{$ odbcinst -j}}
{{unixODBC 2.3.1}}
{{DRIVERS............: /etc/odbcinst.ini}}
{{SYSTEM DATA SOURCES: /etc/odbc.ini}}
{{FILE DATA SOURCES..: /etc/ODBCDataSources}}
{{USER DATA SOURCES..: /home/xxx/.odbc.ini}}
{{SQLULEN Size.......: 8}}
{{SQLLEN Size........: 8}}
{{SQLSETPOSIROW Size.: 8}}

 

{{$ php --version}}
{{PHP 5.4.16 (cli)}}

 

> Quering with PDO returns null for all column values except the 1st one
> ----------------------------------------------------------------------
>
>                 Key: IGNITE-9897
>                 URL: https://issues.apache.org/jira/browse/IGNITE-9897
>             Project: Ignite
>          Issue Type: Bug
>          Components: odbc
>    Affects Versions: 2.6
>         Environment: CentOS
>            Reporter: Roman Shtykh
>            Assignee: Igor Sapego
>            Priority: Major
>
> 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();}}
>  {{}}}
>  {{?>}}
>  



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Mime
View raw message