S
Stapes
Hi
I have set up a routine to merge two Customers records together when
they are found to be duplicates. The Customer may have dependent
invoices. My routine finds all the Invoices linked to the original
Customer (Account Number is the Foreign Key on the Invoices table).
This is not the Primary key on the Customer's table.
To move the Invoices, I have updated the Account Code with the chosen
Account Code. Those Invoices are now shown in as being linked to the
New Account.
However, when I go to delete the now unwanted Customers record, it
says there are related records in the Invoice table.
There are not any related records.
Why does it think there is?
I don't want to put Cascade Deletes on this - I don't want any
Invoices accidentally lost.
Do I have to delete the invoices and add them in again?
Stapes
I have set up a routine to merge two Customers records together when
they are found to be duplicates. The Customer may have dependent
invoices. My routine finds all the Invoices linked to the original
Customer (Account Number is the Foreign Key on the Invoices table).
This is not the Primary key on the Customer's table.
To move the Invoices, I have updated the Account Code with the chosen
Account Code. Those Invoices are now shown in as being linked to the
New Account.
However, when I go to delete the now unwanted Customers record, it
says there are related records in the Invoice table.
There are not any related records.
Why does it think there is?
I don't want to put Cascade Deletes on this - I don't want any
Invoices accidentally lost.
Do I have to delete the invoices and add them in again?
Stapes