You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@phoenix.apache.org by "Istvan Toth (Jira)" <ji...@apache.org> on 2023/04/13 07:58:00 UTC
[jira] [Resolved] (PHOENIX-6917) Column alias not working properly in Python
[ https://issues.apache.org/jira/browse/PHOENIX-6917?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Istvan Toth resolved PHOENIX-6917.
----------------------------------
Release Note: If the JDBC column label is set, phoenixdb now uses it as the python DB2 API column description name field, and uses it as the key for DictCursor. (was: Added support for getting CoulmnLabel rather than the CoulmnName)
Resolution: Fixed
I fixed up the fallback case, and committed the patch.
Thank you [~satyakommula] .
> Column alias not working properly in Python
> -------------------------------------------
>
> Key: PHOENIX-6917
> URL: https://issues.apache.org/jira/browse/PHOENIX-6917
> Project: Phoenix
> Issue Type: Bug
> Components: python, queryserver
> Affects Versions: python-phoenixdb-1.2.1
> Reporter: Satya Kommula
> Assignee: Satya Kommula
> Priority: Major
> Fix For: python-phoenixdb-1.2.2
>
>
> Get the columnLabel (the “as name”) rather than the columnName with a cursor.
> {code:java}
> calcite 💎:sql> select c1 as hello, c2 as world from int_tbl;
> +-------------+-------------+
> | c1 | c2 |
> |-------------+-------------|
> | 5 | 0 |
> | -123 | 123 |
> | 1 | 123456 |
> | -123456 | -123456 |
> | 10 | 50 |
> | -2147483648 | 1 |
> | 2147483647 | -2147483648 |
> | <null> | 10 |
> | <null> | <null> |
> | 1 | 1 |
> +-------------+-------------+{code}
>
--
This message was sent by Atlassian Jira
(v8.20.10#820010)