标签: string pyspark
事件总数是多少?
示例数据:
FWD,29052016:09:01,10.56| FWD,29052016:10:53,11.23| FWD,29052016:15:40,23.20
答案 0 :(得分:0)
您需要更改sep(分隔符)参数并将其设置为|:
sep
|
data = spark.read.csv([DATA_PATH], inferSchema = True, header = True, sep = "|")