How to join/merge a list of dataframes with common keys in ...
stackoverflow.com › questions › 44516409Jun 13, 2017 · from pyspark import SparkContext SparkContext._active_spark_context.stop () sc = SparkContext () sqlcontext = SQLContext (sc) import pyspark.sql.types as t rdd_list = [sc.parallelize ( [ ('John',i+1), ('Paul',i+2), ('George',i+3)],1) \ for i in [100,200,300]] df_list = [] for i,r in enumerate (rdd_list): schema = t.StructType ().add …