Which queen of Spain was married to Ferdinand V and was later succeeded by Joanna?
{'directed': True, 'multigraph': False, 'graph': {}, 'nodes': [{'type': 'INTERNAL', 'name_': 'Q5146', 'id': 0, 'label': 'Portuguese'}, {'type': 'QUESTIONS_ENTITY', 'name_': 'Q29', 'id': 1, 'label': 'Spain'}, {'type': 'ANSWER_CANDIDATE_ENTITY', 'name_': 'Q8229', 'id': 2, 'label': 'Latin script'}, {'type': 'INTERNAL', 'name_': 'Q22808320', 'id': 3, 'label': 'Wikimedia human name disambiguation page'}, {'type': 'INTERNAL', 'name_': 'Q499249', 'id': 4, 'label': 'Walter'}, {'type': 'INTERNAL', 'name_': 'Q665407', 'id': 5, 'label': 'Jana'}, {'type': 'QUESTIONS_ENTITY', 'name_': 'Q4248351', 'id': 6, 'label': 'Joanna'}, {'type': 'QUESTIONS_ENTITY', 'name_': 'Q406540', 'id': 7, 'label': 'Ferdinand V'}], 'links': [{'name_': 'P17', 'source': 0, 'target': 1, 'label': 'country'}, {'name_': 'P282', 'source': 0, 'target': 2, 'label': 'writing system'}, {'name_': 'P282', 'source': 4, 'target': 2, 'label': 'writing system'}, {'name_': 'P31', 'source': 4, 'target': 3, 'label': 'instance of'}, {'name_': 'P282', 'source': 5, 'target': 2, 'label': 'writing system'}, {'name_': 'P460', 'source': 5, 'target': 6, 'label': 'said to be the same as'}, {'name_': 'P31', 'source': 7, 'target': 3, 'label': 'instance of'}]}