[ https://issues.apache.org/jira/browse/HIVE-12776?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15086783#comment-15086783 ]
Amareshwari Sriramadasu commented on HIVE-12776: ------------------------------------------------ [~alangates], Let me try to answer your question. bq. what expectations are you putting on the format of Hive's AST? No expectations. Right now there is no way to look at AST of an expression. For ex: case when dim.x=0 then m1 else m2 end. You can get AST only for a query. The patch is adding utility method to get AST corresponding to an expression and not changing any of the existing parsing or any grammar. I did not understand why this would happen - "Without that though anyone who calls this method may see different AST's depending on the version of Hive they are working with". > Add code for parsing any stand-alone HQL expression > --------------------------------------------------- > > Key: HIVE-12776 > URL: https://issues.apache.org/jira/browse/HIVE-12776 > Project: Hive > Issue Type: Improvement > Reporter: Rajat Khandelwal > Assignee: Rajat Khandelwal > Attachments: HIVE-12776.01.patch, HIVE-12776.02.patch > > > Extensions that use Hive QL as their standard language, will benefit from > this. > Apache Lens uses HQL as its language of choice. To support that, it depends > on a fork of Hive, which has such code. I'm planning to port that to Apache > Hive. > Relevant commit: > https://github.com/InMobi/hive/commit/7caea9ed1d269c1cd1d1326cb39c1db7e0bf2bba#diff-fb3acd67881ceb02e83c2e42cf70beef -- This message was sent by Atlassian JIRA (v6.3.4#6332)