I have a table which contains a column called region, the region contains 2 values - Mexico and USA. I want to download a sample subset of the table, but what I need is the values should be based on both USA and MEXICO.
I have tried these queries - SELECT * FROM TBL WHERE REGION LIKE 'us%' or REGION LIKE 'mexic%'
SELECT * FROM TBL WHERE REGION IN ("us", "mexico") LIMIT 1000
The AND condition doesn't works in the above query. Also the above query only returns one of the regions. What I need is 50% of USA and 50% MEXICO in the sample table. Can this be done using any window functions or any simpler method would also be helpful.
P.S - The sample record is to be showcased in a DECK (PPT) presentation.