-
-
Notifications
You must be signed in to change notification settings - Fork 178
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix local timezone #550
Fix local timezone #550
Conversation
can you explain case DATE, TIMESTAMP, TIMESTAMP_DTY:
par.oPrimValue = tempTime.In(conn.dbTimeZone) all this type store datetime without timezone information. so you now returning the value in timezone? |
Thanks for pointing out. Yes, you are right, I thought about it more, and changed to: par.oPrimValue = time.Date(tempTime.Year(), tempTime.Month(), tempTime.Day(),
tempTime.Hour(), tempTime.Minute(), tempTime.Second(), tempTime.Nanosecond(), time.Local) This way, the Here is why: Before commit bbeff0e,
So in After commit bbeff0e, that is no longer the case. |
ok |
I make these changes in last commit |
database server timezone +03:00
this confirmed by select SYSTIMESTAMP AT TIME ZONE DBTIMEZONE from dual; the result: |
Thanks, will you make a new release anytime soon? I can test your new version. |
I noticed in your latest commit you didn't fix case TimeStampeLTZ, TimeStampLTZ_DTY:
tempTime, err := converters.DecodeDate(par.BValue)
if err != nil {
return err
}
par.oPrimValue = tempTime
if conn.dbTimeZone != time.UTC {
par.oPrimValue = time.Date(tempTime.Year(), tempTime.Month(), tempTime.Day(),
tempTime.Hour(), tempTime.Minute(), tempTime.Second(), tempTime.Nanosecond(), conn.dbTimeZone)
} Your test result look correct because the |
Thanks! When should I expect a new release? |
within days. I will fix other issues and make the release |
A small followup to fix #546