Use JOIN. Modify your query according to the example given below:
select * from table1 join (select distinct id from table2 limit 10) AS someName
on (table1.id=someName.id)
Tags: MySQL, Subquery, Limit, Workaround, Database, SQL, Programming
Disclaimer:Pak/ed and the contributors are not responsible for any errors contained and are not liable for any damages resulting from the use of this material. Disclaimer
Home Disclaimer Advertise Contact Privacy Policy
Copyright © 2004-16 Paked.com. All rights reserved.
Note: Site best viewed at 1024 x 768 or higher screen resolution