Edu scored twice in the last 10 minutes to enable the Seville-based club to stay up at the expense of Celta Vigo, whose 2-1 defeat of Getafe was not enough to grant them survival.

Real Sociedad joined Celta in the Segunda Division next season after a 3-3 draw at Valencia.

Rock-bottom Gimnastic Tarragona's fate was sealed several weeks ago.

It looked bleak for Betis with Celta and Athletic Bilbao both winning entering the latter stages of their games.

It meant Betis also had to win and they managed it thanks to Brazilian striker Edu. He headed home the opener with 10 minutes to go and drilled home a second in the closing stages.

Celta went into the final day third from bottom but with genuine hope of staying up. It didn't start well for Hristo Stoichkov's men against Getafe, however, Pablo Redondo putting the visitors ahead.

But Habib Bamogo equalised and Matias Lequi then scored to hand Celta a win which ultimately proved futile.

Athletic were also in danger at the start of play - they were just a point ahead of Celta - but they saw off Levante 2-0 thanks to an own goal by Jose Manuel Serrano and an Igor Gabilondo header.

The odds were stacked against Sociedad although they went out with a battling performance at Champions League qualifiers Valencia.

Gaizka Garitano and David Villa exchanged early goals before a Victor Lopez own goal put Los Che in front.

Inigo Diaz de Cerio equalised only for a Mikel Alonso own goal to restore the hosts' advantage.

But another own goal, this time from Emiliano Moretti, at least allowed Sociedad to depart with their heads held high.

Sunday afternoon's other early game ended in a 3-1 win for Deportivo La Coruna at Espanyol.

The Primera Liga title will be decided later Sunday.

If Real Madrid beat Real Mallorca at the Bernabeu, then they will claim the crown for the first time since 2003. Should they lose defending champions Barcelona and Sevilla can snatch the trophy.

Barca visit Gimnastic while Sevilla host a Villarreal side chasing a UEFA Cup spot.