这段代码
administrativeRanksInfoDF.orderBy(administrativeRanksDF.col("administrative_id")).cache()
administrativeRanksInfoDF.foreachPartition(partition => {
partition.foreach(line => { //这一行报错
println(line)
})
})
执行报错,如下:
Error:(58, 9) value foreach is not a member of Object
p.foreach(t=>{