SELECT * FROM TablaA a, TablaB b WHERE a.activo = b.activo AND a.activo = 1 ORDER BY a.fechaAlta DESC