There is precedence with logical operators. When in doubt, use parenthesis.
In your case:
SELECT * FROM database WHERE (name = var1 OR name = var2 OR name = var3) AND id < 200
Your original query was interpreted as follows because the AND
has higher precedence.
SELECT * FROM database WHERE name = var1 OR name = var2 OR (name = var3 AND id < 200)
Update
As commented by Rocket, you could condense your OR
statements to IN since they operate on the same field. Doing so would remove the need for parentheses.
SELECT * FROM database WHERE name IN (var1,var2,var3) AND id < 200
Nonetheless, understanding the difference between the two original queries is important as you inevitably will write queries with multiple conditions.