Using SharePoint 2007 (and SharePoint Designer), is there a way of faking the cascade delete that I understand is available in SharePoint 2010?
I have two custom lists: Orders and Line Items. The Line Items list has an Order ID field that's a lookup to the ID field in the Orders list. That's what keeps track of all the line items for any particular order. What I'm trying to do is create a workflow in SharePoint Designer, or a couple looping ones, that will delete all the associated Line Items if a user decides to cancel their order (delete the Order item).
Currently, if an Order that has associated Line Items is deleted, the Order ID field for each of those Line Items goes null. I thought that I could make a "change" workflow that would delete any Line Item that has an empty Order ID field. But, apparently, SharePoint doesn't see the nulling out of the the Order ID field as a "change."
So, back to the drawing board. I know how many Line Items each Order contains because I have a Count field in the Orders list that's a Count Related lookup to the Line Items list. I'm thinking maybe I could use this to make a couple of looping workflows that delete all the associated Lime Items before deleting the Order itself, but I haven't figured out how to do this yet. I may try adding the Custom Workflow Activity Pack from Codeplex so I can investigate the “While Workflow" action to perhaps help do the looping.
Anyway, I thought I'd post my problem here in case anyone has any ideas.