select t1.* from t1,t2 where t1.f1=t2.f1 and t1.f2=t2.f2 and t2.f3='xx';