Re: SparkSQL to read XML Blob data to create multiple rows

2017-07-08 Thread Amol Talap
--+ > |Description| Title| > +---+--------+ > |Description_1.1|Title1.1| > |Description_1.2|Title1.2| > |Description_1.3|Title1.3| > +---++ > > > > > From: Talap, Amol <amol.ta...@capgemini.co

RE: SparkSQL to read XML Blob data to create multiple rows

2017-06-29 Thread Talap, Amol
Thanks so much Zhang. This definitely helps. From: Yong Zhang [mailto:java8...@hotmail.com] Sent: Thursday, June 29, 2017 4:59 PM To: Talap, Amol; Judit Planas; user@spark.apache.org Subject: Re: SparkSQL to read XML Blob data to create multiple rows scala>spark.version res6: String = 2.

Re: SparkSQL to read XML Blob data to create multiple rows

2017-06-29 Thread Yong Zhang
+---++ |Description_1.1|Title1.1| |Description_1.2|Title1.2| |Description_1.3|Title1.3| +---++ From: Talap, Amol <amol.ta...@capgemini.com> Sent: Thursday, June 29, 2017 9:38 AM To: Judit Planas; user@spark.apache.org Subje

Re: SparkSQL to read XML Blob data to create multiple rows

2017-06-29 Thread Judit Planas
rets, Eva Regards, Amol *From:*Judit Planas [mailto:judit.pla...@epfl.ch] *Sent:* Thursday, June 29, 2017 3:46 AM *To:* user@spark.apache.org *Subject:* Re: SparkSQL to read XML Blob data to create multiple rows Hi Amol, Not sure I understand completely your question, but the SQL function "ex

RE: SparkSQL to read XML Blob data to create multiple rows

2017-06-29 Thread Talap, Amol
: Judit Planas [mailto:judit.pla...@epfl.ch] Sent: Thursday, June 29, 2017 3:46 AM To: user@spark.apache.org Subject: Re: SparkSQL to read XML Blob data to create multiple rows Hi Amol, Not sure I understand completely your question, but the SQL function "explode" may help you: http://s

Re: SparkSQL to read XML Blob data to create multiple rows

2017-06-29 Thread Judit Planas
Hi Amol, Not sure I understand completely your question, but the SQL function "explode" may help you: http://spark.apache.org/docs/latest/api/python/pyspark.sql.html#pyspark.sql.functions.explode Here you can find a nice example: https://stackoverflow.com/questions/38210507/explode-in-pyspark

Re: SparkSQL to read XML Blob data to create multiple rows

2017-06-29 Thread ayan guha
Hi Not sure if I follow your issue. Can you please post output of books_inexp.show()? On Thu, Jun 29, 2017 at 2:30 PM, Talap, Amol wrote: > Hi: > > > > We are trying to parse XML data to get below output from given input > sample. > > Can someone suggest a way to pass

SparkSQL to read XML Blob data to create multiple rows

2017-06-28 Thread Talap, Amol
Hi: We are trying to parse XML data to get below output from given input sample. Can someone suggest a way to pass one DFrames output into load() function or any other alternative to get this output. Input Data from Oracle Table XMLBlob: SequenceID Name City XMLComment 1 Amol Kolhapur