User id sql. Nested sql. select if в oracle. select top(100) id from table_a. выбрать все таблицы oracle.