Github user rxin commented on a diff in the pull request: https://github.com/apache/spark/pull/11262#discussion_r53508447 --- Diff: sql/core/src/main/scala/org/apache/spark/sql/DataFrameReader.scala --- @@ -345,6 +346,46 @@ class DataFrameReader private[sql](sqlContext: SQLContext) extends Logging { } /** + * Loads a CSV file and returns the result as a [[DataFrame]]. + * + * This function goes through the input once to determine the input schema. If you know the + * schema in advance, use the version that specifies the schema to avoid the extra scan. + * + * @since 2.0.0 + */ + def csv(paths: String*): DataFrame = format("csv").load(paths : _*) --- End diff -- I'd keep only the path one, and remove the rest. Also you need to add the scala annotation to enable calling this in Java.
--- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. --- --------------------------------------------------------------------- To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org For additional commands, e-mail: reviews-h...@spark.apache.org