Hi,

A pull request (https://github.com/apache/incubator-zeppelin/pulls)
 created to support such scala syntax.

Thanks,
moon

On Mon, Aug 10, 2015 at 3:27 AM Jeff Zhang <zjf...@gmail.com> wrote:

> >  val orders =
> sc.textFile("file:///Users/jzhang/Downloads/SampleData.csv")
> >            .map{line=>line.split(",")}
>
> The above code won't compile successfully, raise error
> > orders: org.apache.spark.rdd.RDD[String] = MapPartitionsRDD[51] at
> textFile at> <console>:39 > <console>:1: error: illegal start of definition
> .map{line=>line.split(",")}
>
> I only have to write it as following to make it pass the compilation.
>
> > val orders =
> sc.textFile("file:///Users/jzhang/Downloads/SampleData.csv").map{
> >             line=>line.split(",")}
>
> I am not sure why. Is it intended or difficult to make it compatible with
> scala syntax ?
>
> BTW, I am using zeppelin 0.5
>
>
> --
> Best Regards
>
> Jeff Zhang
>

Reply via email to