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

ASF GitHub Bot commented on PHOENIX-6917:
-----------------------------------------

stoty commented on PR #124:
URL: 
https://github.com/apache/phoenix-queryserver/pull/124#issuecomment-1497375150

   I have run some local tests, and for me the test passes without your change 
(i.e. with column_name).
   In my tests, I received "BEVERAGE" in both columns in the protobuf reply.
   I tested with PQS head and Phoenix 5.2.0-SNAPSHOT.
   
   Having said that, the behaviour that I am seeing sounds like a bug in either 
Avatica or Phoenix, and I agree that we should use label instead of column_name.
   
   However, we also need to make the same change here:
    
https://github.com/apache/phoenix-queryserver/blob/56344687383b6622eb953101ff982678f8583895/python-phoenixdb/phoenixdb/cursor.py#L389




> Column alias not working properly
> ---------------------------------
>
>                 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)

Reply via email to