apache / apache/kyuubi

[Bug] JDBC driver Incorrect/different results with getDate, getTimestamp and getTime with Calendar in ResultSet

Open
#6,730 1 comment 0 reactions 0 assignees View on GitHub
kind:bug priority:major
Dominant language
Scala
Stars
2.4k
Forks
1k
PR merge metrics
No merged PRs in 30d

Description

### Code of Conduct

- [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)

### Search before asking

- [X] I have searched in the [issues](https://github.com/apache/kyuubi/issues?q=is%3Aissue) and found no similar issues.

### Describe the bug

Hi Team,

when we use kyuubi-hive-jdbc-shaded-1.9.2 driver from tableau we are getting different values for date and timestamp with different time zone.

for Eg:

**Date field.**

Actual value --> 2024-01-15 , in tableau it is showing as 2024-01-14

**Timestamp field**

Actual value --> 2023-05-04 06:24:58 In tableau desktop if I'm using from IST time zone it is showing as 2023-05-04 00:54:58

if I'm Tableau desktop from CE time zone it is showing as 2023-05-04 04:24:58 and using BST time zone 2023-05-04 05:24:58

we are suspecting somewhere Date and timestamp field are convert into epoch time and resulting out into UTC .

Is there any way that we need avoid the conversions and display the actual value .
[Date_Time_Tableau_issue.xlsx](https://github.com/user-attachments/files/17374529/Date_Time_Tableau_issue.xlsx)
Screenshot from tableau desktop

### Affects Version(s)

1.9.2

### Kyuubi Server Log Output

_No response_

### Kyuubi Engine Log Output

_No response_

### Kyuubi Server Configurations

_No response_

### Kyuubi Engine Configurations

_No response_

### Additional context

_No response_

### Are you willing to submit PR?

- [ ] Yes. I would be willing to submit a PR with guidance from the Kyuubi community to fix.
- [X] No. I cannot submit a PR at this time.

Contributor guide

Open the contributing guide

Research direction

No source file or test is named. Start by reproducing the ResultSet getDate, getTimestamp, and getTime behavior with Calendar through the kyuubi-hive-jdbc-shaded-1.9.2 driver and Tableau across the reported time zones; done means date and timestamp values are consistent with the source values and timezone expectations.

Written by the indexing model from the issue text.

Assessment

Tech stack
scala, sql
Domain
api, database
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.