Basically I have a list of merchantid's 18,36,90. I want to pull all rows with these merchantid's.
In the first case I want pull the rows with the merchantid's in this order 18,36,90. The following MYSQL statement pulls them in the correct order because coincidentally the merchantid's or in ascending order:
SELECT * FROM tblMerchants WHERE merchantid=18 OR merchantid=36 OR merchantid=90
What if I want to pull the rows with the merchantid's in a different order like 36,90,18 that isn't ascending or descending? Thanks!
order by rand()should work