Most people are pretty good at getting their civil residency from the National Police and are keen to show that they are not just passing trade. However, not everyone is aware that there is more to residency than your sheet of green paper (Civil Resident).
For the fiscal residency you need a Certificate from the Tax Office and for this you have to declare every year your Income Tax in Spain. Civil residency is, in fact, pretty useless when it comes to financial matters. For example, when capital gains or inheritance tax is due - if you can't prove you are a fiscal resident then you can end up paying non-resident taxes and there are big differences between the two.