When deleting certain documents, you might get a
database constraint error. This is due to the case that
some relationships are set as required to import tables.
The attached scipts sets the FK to null.
This enables you to, e.g. import report lines and then
delete some of the imported lines.
Import Table Contraints