Support Questions
Find answers, ask questions, and share your expertise
Announcements
Alert: Welcome to the Unified Cloudera Community. Former HCC members be sure to read and learn how to activate your account here.

how to load a CSV file in elasticsearch using pyspark?

Highlighted

how to load a CSV file in elasticsearch using pyspark?

New Contributor

please share some sample document to load a sample csv file to elasticsearch using pyspark

1 REPLY 1

Re: how to load a CSV file in elasticsearch using pyspark?

@Rajesh AJ

Here is a link to the Elasticsearch for Apache Hadoop documentation: Elasticsearch for Apache Hadoop

The documentation does a very good job of showing examples for writing data to Elasticsearch using Spark. Most of the examples cover Scala or Java, but the end of that page does give an example using PySpark.

This blog may also be helpful: https://prasanthkothuri.wordpress.com/2016/06/17/integrating-hadoop-and-elasticsearch-part-2-queryin...

You may also find this blog article helpful for loading CSV files into Spark DataFrames: http://www.nodalpoint.com/spark-dataframes-from-csv-files/

Don't have an account?
Coming from Hortonworks? Activate your account here