If you are planning on working for a company in Spain you are going to need a social security number in order for your employer to register you as an official employee. Before, you could apply for the number yourself. Now it's your employer who should obtain it for you through their advisor.
Alternatively if you are looking to become self employed in Spain we can help you with that. Our tax adviser can provide details of fees and options that best suites your situation.