Joda time DateTime incorrectly stores in database

前端 未结 7 1653
青春惊慌失措
青春惊慌失措 2020-12-30 08:18

I\'m storing JodaTime DateTime field to timestamptz column by using org.jadira.usertype:usertype.jodatime:1.9. App server has +4 time

相关标签:
7条回答
  • 2020-12-30 09:19

    I had the same issue. Specifying app and db zones in config solved the issue.

                <prop key="jadira.usertype.autoRegisterUserTypes">true</prop>
                <prop key="jadira.usertype.databaseZone">America/Los_Angeles</prop>
                <prop key="jadira.usertype.javaZone">America/Los_Angeles</prop>
    
    0 讨论(0)
提交回复
热议问题