There is no confusion in Filter and where in spark sql since both gives same result.
// The following are equivalent: employee.filter($"age" > 15) employee.where($"age" > 15)
employees.filter($"emp_id".isin(items:_*)).show
employees.where($"emp_id".isin(items:_*)).show
Result is same for the
both
Filter is
simply the standard Scala name for such a function, and
where
is for people who prefer SQL.