Data Loader 根据其配置方式使用 SOAP API 或 BULK API。
如果 .csv 文件中的相应值不符合特定格式或不符合组织的时区设置,用户可能无法导入对“日期”、“日期时间”和“时间”数据类型字段的更改, 除非正确格式化以使 API 接受这些更改。
有关 Data Loader 独有的所有支持格式,请参考Data Loader 支持的数据类型。
如何在 CSV 文件中格式化“日期”和“日期时间”数据
这是用于避免错误和挫折的正确格式:
“日期”字段可接受的格式
YYYY-MM-DD
YYYY-MM-DD hh:mm:ss
YYYY-MM-DD hh:mm:ss
YYYY-MM-DDThh:mm:ssZ
YYYY-MM-DDThh:mm:ss.sssZ
“日期时间”字段可接受的格式
YYYY-MM-DD hh:mm:ss
YYYY-MM-DDThh:mm:ssZ
YYYY-MM-DDThh:mm:ss.sssZ
“时间”字段可接受的格式
hh:mm:ss.sssZ(例如 07:00:00.000Z)
示例场景
场景:如果您组织的时区设置为“中国/台湾时区 GMT+8”:
“日期”和 Data Loader 时区为 GMT+0、GMT 或空白
导入电子表格中的示例数据可以是以下之一:
2011-01-10
2011-01-10 00:00:00
2011-01-10T00:00:00Z
2011-01-10T00:00:00.000Z
“日期”和 Data Loader 时区为 GMT+8
导入电子表格中的示例数据必须是以下之一:
2011-01-10 8:00:00
2011-01-10T08:00:00Z
2011-01-10T08:00:00.000Z
备注:如果将 hh:mm:ss 设置为 00:00:00,Salesforce 中的导入日期数据将显示前一天(“2011-01-09”而不是“2011-01-10”)。
“日期时间”和 Data Loader 时区为 GMT+8
2011-01-10TXX:XX:XXZ
2011-01-10TXX:XX:XX.XXXZ
关于这些格式的附加信息
您在导入电子表格中的示例数据必须是以下选项之一,才能使“日期时间”准确显示您在电子表格中导入的内容:
2011-01-10 XX:XX:XX
XX:XX:XX 或 XX:XX:XX.XXX 代表您输入的可变时间。
这些字符串中的“T”表示时间元素的开始。
“Z”是特殊的 GMT 名称。
此信息仅适用于最新版本的 Data Loader
其他帮助资源
000385167

We use three kinds of cookies on our websites: required, functional, and advertising. You can choose whether functional and advertising cookies apply. Click on the different cookie categories to find out more about each category and to change the default settings.
Privacy Statement
Required cookies are necessary for basic website functionality. Some examples include: session cookies needed to transmit the website, authentication cookies, and security cookies.
Functional cookies enhance functions, performance, and services on the website. Some examples include: cookies used to analyze site traffic, cookies used for market research, and cookies used to display advertising that is not directed to a particular individual.
Advertising cookies track activity across websites in order to understand a viewer’s interests, and direct them specific marketing. Some examples include: cookies used for remarketing, or interest-based advertising.