Hi David, Use something like : Val outputRDD = rdd.flatMap(keyValue => keyValue._2.split(";").map(value => (keyvalue._1, value)).toArray)
Thanks and Regards, Suraj Sheth -----Original Message----- From: david [mailto:david...@free.fr] Sent: Tuesday, November 04, 2014 1:28 PM To: u...@spark.incubator.apache.org Subject: Re: Key-Value decomposition Hi, But i've only one RDD. Hre is a more complete exemple : my rdd is something like ("A", "1;2;3"), ("B", "2;5;6"), ("C", "3;2;1") And i expect to have the following result : ("A",1) , ("A",2) , ("A",3) , ("B",2) , ("B",5) , ("B",6) , ("C",3) , ("C",2) , ("C",1) Any idea about how can i achieve this ? Thank's -- View this message in context: http://apache-spark-user-list.1001560.n3.nabble.com/Key-Value-decomposition-tp17966p18036.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 --------------------------------------------------------------------- To unsubscribe, e-mail: user-unsubscr...@spark.apache.org For additional commands, e-mail: user-h...@spark.apache.org