I want to make a dataframe with 110 columns, so i create a class with 110 attributes when i try to convert the rdd to dataframe.
case class Myclass(var cin_nb:String,...........,var last:String)
import sqlContext.implicts._
file2.map(_.split(" ")).map(a=>Myclass(a(0),a(1),a(2),a(3),.....a(110)).ToDf()
I got this error:
not enough arguments for method apply: (cin_nb: String,...........,last:String)
i'm using scala and spark 1.6. Thank you
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…