SELECT oe.ofeid, oe.empid, a.area, oe.cargotitulo, oe.ciudad, oe.anonimo_id, oe.observaciones, oe.fechafinal, e.empresa as nombreempresa, e.fraseoeanonima, p.pais as nombrepais, oe.fechaot, oe.cargodescr, oe.longitud, oe.latitud, oe.zoom, el.logo, el.fecha_actualizacion , oe.fechaot as rank FROM ofertasempleo AS oe INNER JOIN statusoe AS soe ON (soe.ofeid = oe.ofeid) INNER JOIN empresas AS e ON (oe.empid = e.empid) INNER JOIN areas AS a ON (a.areid=oe.area) INNER JOIN paises AS p ON (oe.pais = p.paiid) LEFT JOIN empresas_logo AS el ON (oe.empid = el.empid) WHERE soe.activa_id = 19 AND e.status_id = 7 AND oe.fechafinal >= CURRENT_DATE AND oe.pais = 140 AND (carrera1 = 30 or carrera2 = 30 or carrera3 = 30) AND oe.area IN (10,10) AND industria IN (45,45) ORDER BY rank DESC, fechafinal