Hi,
convert then to temporary table and write a SQL, that will also work.
Regards,
Gourav
On Sun, May 7, 2017 at 2:49 AM, Zeming Yu wrote:
> Say I have the following dataframe with two numeric columns A and B,
> what's the best way to add a column showing the difference between the two
> colu
OK. I've worked it out.
df.withColumn('diff', col('A')-col('B'))
On Sun, May 7, 2017 at 11:49 AM, Zeming Yu wrote:
> Say I have the following dataframe with two numeric columns A and B,
> what's the best way to add a column showing the difference between the two
> columns?
>
> +