I have a main table with **ResId** primary key.

**ResId** is foreign key for over 200 tables. In these tables insert **ResId** with unique value. 

For example **ResId** in table1 is **1,7,50** and in table2 is **3,4,21** and table3 is **2,6,81** , ...

How can I get table name with specific **ResId** from main table. 

For example when **ResId=3** Result is **table2** and when **ResId=6** result is **table3**