View Single Post
  #2 (permalink)  
Old 04-21-2008, 08:54 PM
Dimitar
 
Posts: n/a
Default ANY answer. Re: Querying the Database

One idea:
Code:
select u.username,
  (case u.planID
    when 1 then (select info from t1)
    when 2 then (select info from t2)
    when 3 then (select info from t3)
    when 4 then (select info from t4)
  end) as info
from users u
;
Hope this helps,
Dimitar
Reply With Quote