How To Recode A Door Lock

I have to do this with my car. I have two questions about how you did this. Are the door locks and trunk lock the same key or is the ignition key supposed to match the door locks? Did you have extra pins or are they all the same but in different orders?

Thanks a ton

Dave