question

pits avatar image
pits asked

datapurge job failing

Hello Experts, My purge database job is failing with below error message since today morning. Message : DELETE statement conflicted with COLUMN REFERENCE constraint 'MANIA_AED_fk'. The conflict occurred in database 'ARIA', table 'MANIA', column 'AED'. [SQLSTATE 23000] (Error 547) PurgeAllData: failed to delete DataHeader where dataid = 15467 [SQLSTATE 42000] (Error 50000) The statement has been terminated. [SQLSTATE 01000] (Error 3621). The step failed. can you please assist. rgds,
jobfailingpurge
10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

1 Answer

·
Grant Fritchey avatar image
Grant Fritchey answered
You're attempting to delete data that has a foreign key reference to another table. You have to delete the data in the child table first. Then you'll be able to delete the other data. Take a look at the definition of the foreign key constraint MANIA_AED_fk to know which table you need to worry about.
2 comments
10 |1200

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

pits avatar image pits commented ·
in the same table of FK properties...primary key is mentioned as false...! can you please advise
0 Likes 0 ·
Grant Fritchey avatar image Grant Fritchey ♦♦ commented ·
I don't understand, primary key is false? Where are you reading that?
0 Likes 0 ·

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.