Sociedad won 2-1 in Seville to reclaim the advantage in the race for the final Champions League spot in Spain.
Ivan Rakitic put Sevilla ahead in the 10th minute but he turned from hero to villain seven minutes later with a headed own goal.
Imanol Agirretxe then scored what turned out to be a winner with Sevilla then having unused substitute Jose Antonio Reyes given a straight red card and sent from the bench.
Earlier in the evening a solitary goal by Jeremy Mathieu was enough for Valencia to see off Getafe 1-0 in Madrid.
The French centre-back struck just before half-time to give the visitors the lead in what was a largely uneventful match at the Coliseum Alfonso Perez.
The result means Getafe missed an opportunity to gain ground in their bid to qualify for the Europa League and remain in ninth place in the table.
Elsewhere, Granada took a huge step towards securing their La Liga future with a 3-0 victory over fellow strugglers Osasuna.
Youssef El Arabi's 23rd-minute goal gave Granada the lead and victory was all but secured when Fernando Nano felled Yacine Brahimi in the penalty area with 10 minutes remaining.
Nano saw red and Guilherme Siqueira's cheeky dinked penalty wrapped up three vital points, before Diego Buonanotte added gloss to the scoreline late on.
The win sends Granada seven points clear of the relegation zone but Osasuna will be looking anxiously over their shoulders, especially with a final-day clash with Real Madrid awaiting them.