var id="1,2,3,4,5,............................";
select * from A where ID in (id)
因为这个id是某一张表中记录的字段,少的有时候只有一个,多的可能有上千个。
只能根据这个ID来查询需要的内容,有没有高效的查询方式,麻烦给指点下,谢谢!
相关问题
- how to get selected text from iframe with javascri
- how to solve the issue with group by and aggregate
- Get all from one table and COUNT from another
- PostgreSQL + Rails: is it possible to have a write
- SQL join two tables with specific condition
先把1,2,3,4,5,............................插入一个表(可临时表)中,然后用select * from A where exists