Support Questions

Find answers, ask questions, and share your expertise
Announcements
Welcome to the upgraded Community! Read this blog to see What’s New!

getting error while persisting spark output to hive

avatar
Rising Star
scala> df.select("name","age").write().format("com.databricks.spark.csv").mode(SaveMode.Append).saveAsTable("PersonHiveTable");
<console>:39: error: org.apache.spark.sql.DataFrameWriter does not take parameters
1 ACCEPTED SOLUTION

avatar

@Divya Gehlot

Since this is scala and not Java, the following should work

df.select("name","age").write.format("com.databricks.spark.csv").mode(SaveMode.Append).saveAsTable("PersonHiveTable");

View solution in original post

1 REPLY 1

avatar

@Divya Gehlot

Since this is scala and not Java, the following should work

df.select("name","age").write.format("com.databricks.spark.csv").mode(SaveMode.Append).saveAsTable("PersonHiveTable");
Labels