首页 > 其他 > 详细

用Data Loader 处理Datetime型数据

时间:2017-03-14 17:22:25      阅读:162      评论:0      收藏:0      [点我收藏+]

在用Dataloader导入数据时,对于DateTime格式的数据,考虑到时区和格式的问题,要做些简单处理.

Date Formats
We recommend you specify dates in the format yyyy-MM-ddTHH:mm:ss.SSS+/-HHmm:

  • yyyy is the four-digit year
  • MM is the two-digit month (01-12)
  • dd is the two-digit day (01-31)
  • HH is the two-digit hour (00-23)
  • mm is the two-digit minute (00-59)
  • ss is the two-digit seconds (00-59)
  • SSS is the three-digit milliseconds (000-999)
  • +/-HHmm is the Zulu (UTC) time zone offset

The following date formats are also supported:

  yyyy-MM-dd’T’HH:mm:ss.SSS’Z’

  yyyy-MM-dd’T’HH:mm:ss.SSS Pacific Standard Time

      yyyy-MM-dd’T’HH:mm:ss.SSSPacific Standard Time

  yyyy-MM-dd’T’HH:mm:ss.SSS PST

  yyyy-MM-dd’T’HH:mm:ss.SSSPST

  yyyy-MM-dd’T’HH:mm:ss.SSS GMT-08:00

  yyyy-MM-dd’T’HH:mm:ss.SSSGMT-08:00

  yyyy-MM-dd’T’HH:mm:ss.SSS -800

  yyyy-MM-dd’T’HH:mm:ss.SSS-800

  yyyy-MM-dd’T’HH:mm:ss

  yyyy-MM-dd HH:mm:ss

  yyyyMMdd’T’HH:mm:ss

  yyyy-MM-dd

  MM/dd/yyyy HH:mm:ss

  MM/dd/yyy

以下是我转换Datetime数据的过程,因为在中国,时区应该在GMT基础上+8小时

技术分享

 

用Data Loader 处理Datetime型数据

原文:http://www.cnblogs.com/wicky-666/p/6549509.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!