The motion of censure against Spanish Prime Minister and the election of socialist leader Sanchez as his successor has briefly spooked markets. But in the end it may make less difference than it seems at first sight.
Rajoy was already having problems governing. He secured the 2018 budget only by making significant financial concessions to the Basque Country in exchange for the support of the five members of parliament of the Basque Nationalist Party. Following the adoption of the budget, the centre-right Ciudadanos party, which had hitherto supported the government, announced it was moving into opposition. Instead of a minority government with the ability to negotiate some legislation (albeit at a cost), Rajoy´s government became one with little if any prospect of getting significant legislation through parliament. The adoption of the 2018 budget in principle allowed Rajoy to survive until scheduled elections in 2020, but as little more than a caretaker.
His success in the censure motion leaves Sanchez in a similarly weak position. He commands even less seats in the parliament than Rajoy. The coalition he put together for the censure vote was a negative one, focused more on ejecting Rajoy than supporting Sanchez. There is no government programme shared by the parties who put Sanchez in the Moncloa and indeed, given their diversity, it would be impossible to put one together. He has committed himself to implement Rajoy´s budget, not only to bring the Basque nationalists on board, but also because it would be impossible to devise a new one that would secure approval in the parliament. This will allow him to set spending limits for 2019 and, if he wants to, get though to the scheduled elections in 2020. But he will be able to do little else. He may manage some actions at the margins to please his voters, but the other parties in the parliament will be in no mood to do him electoral favours.
In short whether Rajoy or Sanchez is in the Moncloa, makes little difference: a minority government able to survive but with little if any chance to get its legislation adopted. Moreover, both the Rajoy and Sanchez are pro-EU and pro-Europe. Neither would intentionally take any action that would put Spain´s membership of the Euro in danger. Spain is not Italy.