Can someone give me an example of a SQL statement which embeds the CASE condition on WHERE clause? E.g.
Select the fields Employee, Gender, Division from the table "Employees" where (if the Gender = "Male" Division = "Sales", if Gender = "Female" Division = "Accounts").
So for Male gender, only male employees in Sales division should show. For Female gender, only female employees in Accounting will show.
I know there could be other ways but I would like it to see it in the WHERE clause which is dictated by other conditions.
Select the fields Employee, Gender, Division from the table "Employees" where (if the Gender = "Male" Division = "Sales", if Gender = "Female" Division = "Accounts").
So for Male gender, only male employees in Sales division should show. For Female gender, only female employees in Accounting will show.
I know there could be other ways but I would like it to see it in the WHERE clause which is dictated by other conditions.