尝试使用Scala访问Spark的Dataframe操作时,
返回字符文字错误。
[ERROR] /home/cloudera/sharedCloudera-vm/hw3-skeleton/Q2/src/main/scala/edu/gatech/cse6242/Q2.scala:25: error: unclosed character literal
[INFO] val filterNodes = nodes.filter(df('weight')>=5)
答案 0 :(得分:-3)
问题在于单引号''
使用双引号“
解决 val filterNodes = nodes.filter(df("weight")>=5)