I have a Netherlands visa. My plans have changed drastically. I would be staying most number of days in Spain. Can i have my POE in Madrid? Will it be a problem if neither my POE not my maximum number of days are not in the country from where i got my Schengen visa?
It might be a problem, especially if you have single entry visa. If you enter Spain with single entry visa issued by Netherlands, you will likely be asked to confirm that Netherlands is either your main destination or the place of the longest stay. (See another answer to the similar question and follow the links)