 He continued to be everpresent from 2004 to 2006, as the side achieved two consecutive ninth-place finishes in La Liga.Rivas played the first of the following two seasons with Real Sociedad, appearing irregularly as the Basques were relegated and being loaned to Cádiz CF of the second level for 2007–08, in another ill-fated campaign.Rivas excelled in the following second-tier seasons with Real Sociedad, rarely missing a match and helping the club return to the top level in his second year, while collecting a combined 22 yellow cards.