Comment
Markus Kraus
Kilo Sage

Note: This is now a OOTB capability (via property "problem.role.relate_closed_incidents"), there is a bug in the SOW, but here is the fix:
Bug: Related Closed Incident to Problem - ServiceNow Community