OK I got it working with:

z.map(row => (row.map(element => element.split("=")(0)) zip row.map(element
=> element.split("=")(1))).toMap)

But I'm guessing there is a more efficient way than to create two separate
lists and then zip them together and then convert the result into a map.



--
View this message in context: 
http://apache-spark-user-list.1001560.n3.nabble.com/Converting-Apache-log-string-into-map-using-delimiter-tp18641p18643.html
Sent from the Apache Spark User List mailing list archive at Nabble.com.

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscr...@spark.apache.org
For additional commands, e-mail: user-h...@spark.apache.org

Reply via email to