select chg.location, aa.*from
(select * from TABLEwhere location=10135)aa, TABLE chg
where if (aa.location=(10135) then (select * from TABLE where location=99999) else (select * from TABLE where location=99998) )