csv文件写入hdfs,日期格式字段由yyyy-MM-dd-HH.mm.ss.SS转换为yyyy-MM-dd HH:mm:ss的问题
- Dominant language
- Java
- Stars
- 17.4k
- Forks
- 5.7k
- PR merge metrics
- No merged PRs in 30d
Description
csv原始数据中有个create_time时间字段格式为2018-06-18-16.39.05.214000(yyyy-MM-dd-HH.mm.ss.SS),导入hive时想变成2018-06-18 16:39:05(yyyy-MM-dd HH:mm:ss)需要怎么配置?
目前使用txtfilereader读、hdfsWriter写:
- txtfilereader:create_time字段"type"="date","format"="yyyy-MM-dd-HH.mm.ss"(指定为其他格式会报错解析不了日期)
- hdfsWriter中的create_time字段"type"="date","format"="yyyy-MM-dd HH:mm:ss" 并没有效果
如何再将 txtfilereader的"yyyy-MM-dd-HH.mm.ss"转换为hdfsWriter的"yyyy-MM-dd HH:mm:ss"呢?
Contributor guide
No contributing guide indexed for this repository
Research direction
Start by tracing how the txtfilereader parses create_time and how hdfsWriter applies its date format, using the configurations shown in the issue. Verify the behavior with the stated input and confirm that the written value is 2018-06-18 16:39:05; the payload names no source files or tests to run.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java
- Domain
- data-engineering
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 25/100