Sorry if the title to this question makes no sense. I really wasn't sure how else to word what I needed to do.
So I have the following tables in my database:
customers customer_id (PK) customer_name website customer_address customer_id (FK) (PK-A) street (PK-B) city region code customer_contact contact_id (PK) contact_name customer_id (FK) customer_contact_phone contact_id (FK) (PK-A) phone_number (PK-B) extension
I am trying to set up a procedure which would allow me to delete all the data pertaining to a specific customer. Now I know how to delete any or all of the addresses pertaining to the customer whose data i am trying to delete. However, I am not know how to properly delete all of the contact data.
My issue is that there can be multiple contacts for a customer, and each contact can have multiple phone numbers. I am not sure how to go about setting up these records for deletion because of how many foreign keys are set up.