how to select multiple names in a single query

sql

Solution

You can do:

select * from users where uname in ("ali", "veli")

As per:

http://www.w3schools.com/sql/sql_in.asp

Problem

I have a sql query which is like that ``` select * from users where uname="ali" and uname="veli" ``` but it is not worked what ı want to do is get the person whose name is "ali" and "veli" but if "ali" is not exist and "veli" is exist, the existed ones should be return. How can I do this. it is easy query but I am confusing.

Original source