Din datamodell är suboptimal. Tänk på:
Person PersonRole Role Table ------ ---------- ---- ----- Id* PersonId* Id* Id* Name RoleId* Name Name TableId
Som sagt...
select dining_table from Dining_Tables where
bus_boy = "Joe Smith" or
waiter = "Joe Smith" or
server = "Joe Smith"
union
select poker_table from Poker_Tables where
dealer = "Joe Smith" or
pit_boss = "Joe Smith"
union
select computer_table from Computer_Tables where
programmer = "Joe Smith"