You can do this either with expr("... IN ...") or isin.

Here is a full example
<https://databricks-prod-cloudfront.cloud.databricks.com/public/4027ec902e239c93eaaa8714f173bcfc/1023043053387187/1075277772969592/2840265927289860/2388bac36e.html>
.

On Wed, Feb 24, 2016 at 2:40 PM, Ashok Kumar <ashok34...@yahoo.com.invalid>
wrote:

> Hi,
>
> I would like to do the following
>
> select count(*) from <table> where column1 in (1,5))
>
> I define
>
> scala> var t = HiveContext.table("table")
>
> This works
> t.filter($"column1" ===1)
>
> How can I expand this to have column1  for both 1 and 5 please?
>
> thanks
>

Reply via email to