put default value inside lit

df.withcolumn("date",lit("constant value"))

On Fri, Jun 30, 2017 at 10:20 PM, sudhir k <k.sudhi...@gmail.com> wrote:

> Can we add a column to dataframe with a default value like sysdate .. I am
> calling my udf but it is throwing error col expected .
>
> On spark shell
> df.withcolumn("date",curent_date) works I need similiar for scala program
> which I can build in a jar
>
>
> Thanks,
> Sudhir
> --
> Sent from Gmail Mobile
>

Reply via email to