i have a big DB, and i wants to create query that i give her two name of tables and she give me the relationships between her.
for example: in my DB i have three table:Person,SupportActitvity and ProcessesSupportActivity. Person related to SupportActitvity , and SupportActitvity related to ProcessesSupportActivity if i want to get the ProcessesSupportActivity for Person i write:
select *
from person
join SupportActivity on Person.PersonId=SupportActivity.PersonId
join ProcessSupportActivity on ProcessSupportActivity.SupportActivityId=SupportActivity.SupportActivityId
I want that when i write that for Person and ProcessSupportActivity he give me the relationships.
he return:
- Person PersonId SupportActivity PersonId
- SupportActivity SupportActivityId ProcessSupportActivity SupportActivityId
Thank you very much!!!!