title: How to add column to one dataframe from another in pyspark?
body: <p>I'm new at pyspark and I was trying to do some tokenization on my data. 
  I have my first dataframe:
  <strong>reviewID|text|stars</strong></p>
  
  <p>I made a tokenization on "text" according to the pyspark documentation:</p>
  
  <pre><code>tokenizer = Tokenizer(inputCol="text", outputCol="words")
  
  countTokens = udf(lambda words: len(words), IntegerType())
  
  tokenized = tokenizer.transform(df2)
  tokenized.select("text", "words") \
      .withColumn("howmanywords", countTokens(col("words"))).show(truncate=False)
  </code></pre>
  
  <p>I got my tokens but now I would like to have transformed dataframe that looks like that:</p>
  
  <p><strong>words|stars</strong></p>
  
  <p>"Words" are my tokens.</p>
  
  <p>So I need to join my first dataframe and tokenized dataframe to get something like that. 
  Could you please help me? How can I add a column to the another dataframe? </p>