[
https://issues.apache.org/jira/browse/HIVE-26745?focusedWorklogId=826635&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-826635
]
ASF GitHub Bot logged work on HIVE-26745:
-----------------------------------------
Author: ASF GitHub Bot
Created on: 16/Nov/22 20:43
Start Date: 16/Nov/22 20:43
Worklog Time Spent: 10m
Work Description: sonarcloud[bot] commented on PR #3769:
URL: https://github.com/apache/hive/pull/3769#issuecomment-1317644409
Kudos, SonarCloud Quality Gate passed! [](https://sonarcloud.io/dashboard?id=apache_hive&pullRequest=3769)
[](https://sonarcloud.io/project/issues?id=apache_hive&pullRequest=3769&resolved=false&types=BUG)
[](https://sonarcloud.io/project/issues?id=apache_hive&pullRequest=3769&resolved=false&types=BUG)
[0
Bugs](https://sonarcloud.io/project/issues?id=apache_hive&pullRequest=3769&resolved=false&types=BUG)
[](https://sonarcloud.io/project/issues?id=apache_hive&pullRequest=3769&resolved=false&types=VULNERABILITY)
[](https://sonarcloud.io/project/issues?id=apache_hive&pullRequest=3769&resolved=false&types=VULNERABILITY)
[0
Vulnerabilities](https://sonarcloud.io/project/issues?id=apache_hive&pullRequest=3769&resolved=false&types=VULNERABILITY)
[](https://sonarcloud.io/project/security_hotspots?id=apache_hive&pullRequest=3769&resolved=false&types=SECURITY_HOTSPOT)
[](https://sonarcloud.io/project/security_hotspots?id=apache_hive&pullRequest=3769&resolved=false&types=SECURITY_HOTSPOT)
[0 Security
Hotspots](https://sonarcloud.io/project/security_hotspots?id=apache_hive&pullRequest=3769&resolved=false&types=SECURITY_HOTSPOT)
[](https://sonarcloud.io/project/issues?id=apache_hive&pullRequest=3769&resolved=false&types=CODE_SMELL)
[](https://sonarcloud.io/project/issues?id=apache_hive&pullRequest=3769&resolved=false&types=CODE_SMELL)
[0 Code
Smells](https://sonarcloud.io/project/issues?id=apache_hive&pullRequest=3769&resolved=false&types=CODE_SMELL)
[](https://sonarcloud.io/component_measures?id=apache_hive&pullRequest=3769&metric=coverage&view=list)
No Coverage information
[](https://sonarcloud.io/component_measures?id=apache_hive&pullRequest=3769&metric=duplicated_lines_density&view=list)
No Duplication information
Issue Time Tracking
-------------------
Worklog Id: (was: 826635)
Time Spent: 0.5h (was: 20m)
> HPL unable to handle Decimal or null values in hplsql mode
> ----------------------------------------------------------
>
> Key: HIVE-26745
> URL: https://issues.apache.org/jira/browse/HIVE-26745
> Project: Hive
> Issue Type: Bug
> Reporter: Ádám Szita
> Assignee: Ádám Szita
> Priority: Major
> Labels: pull-request-available
> Time Spent: 0.5h
> Remaining Estimate: 0h
>
> Decimal or null values coming from Hive service side are not handled properly
> in HPL.
> When we're using beeline in HPL mode then the results of queries such as
> SELECT CAST are returned in RowSet objects directly from HS2 code. This is
> due to HplSqlQueryExecutor expecting RowSet type in OperationRowResult. For
> this RowSet interface, a ColumnBasedSet class brings the imlementation which
> holds a ColumnBuffer list to hold the result data.
> The internal representation however cannot hold BigDecimal values, as seen
> here:
> https://github.com/apache/hive/blob/master/serde/src/java/org/apache/hadoop/hive/serde2/thrift/ColumnBuffer.java#L396
> so while the SELECT CAST query will produce a HiveBigDecimal instance, it
> will be converted to String at
> https://github.com/apache/hive/blob/master/service/src/java/org/apache/hive/service/cli/ColumnBasedSet.java#L110-L112
> before we add this piece of data to the result set.
> Further down the line we will see class java.lang.String cannot be casted to
> class java.math.BigDecimal.
> ColumnBuffer seems like a pretty commonly used code and I don't think we
> would want to try and extend this with the ability the carry decimal types.
> Perhaps we could create a Jira to recreate the BigDecimal value from the
> String representation arriving on the HPL side.
> Since the two issues are both about value conversion I'm aiming to fix these
> in one go.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)
