Delete list items not present in the data hub

aeyzat
Occasional Contributor

Delete list items not present in the data hub

Hello, 

 

I'm creating a data hub in Anaplan in order to have the product hierarchy of 4 models located in only one place. 

The product hierarchy already exists in each of my models.  When i created the hub i cleaned up the hierarchy and delete many items. 

My problem is when i import the data from the data hub module into the hierarchical list of my models, it will add the new items, but if i deleted items in the data hub sources, they will not be deleted in the hierarchical lists.

 

what is the best practice in order to delete items that is not present in the data hub hierarchy when i import the data in the lists of my models ? 

 

Thank you for your help

2 ACCEPTED SOLUTIONS

Accepted Solutions
rob_marshall
Moderator

Re: Delete list items not present in the data hub

@aeyzat 

 

It will be a multistep process:

  • first, and you probably already know this, but you should be loading the hierarchy in your spoke models from views within the data hub, not the actual list
  • In the view, create a line item that is a boolean called Load? which signifies the members to load
  • In your spoke model, load the boolean to a SYS module
  • in your spoke model, create an action that deletes members where the boolean is false
  • in your spoke model, create an action that clears the boolean in the SYS module
  • In your spoke model, create the loading process with these actions
    • Clear the boolean in the SYS module
    • Load the data  from the data hub
    • Delete members where the boolean is false

Hope this helps,

 

Rob

View solution in original post

rob_marshall
Moderator

Re: Delete list items not present in the data hub

@aeyzat 

 

For the Boolean, set it to false, so you are "clearing" all true values.

 

Rob

View solution in original post

3 REPLIES 3
rob_marshall
Moderator

Re: Delete list items not present in the data hub

@aeyzat 

 

It will be a multistep process:

  • first, and you probably already know this, but you should be loading the hierarchy in your spoke models from views within the data hub, not the actual list
  • In the view, create a line item that is a boolean called Load? which signifies the members to load
  • In your spoke model, load the boolean to a SYS module
  • in your spoke model, create an action that deletes members where the boolean is false
  • in your spoke model, create an action that clears the boolean in the SYS module
  • In your spoke model, create the loading process with these actions
    • Clear the boolean in the SYS module
    • Load the data  from the data hub
    • Delete members where the boolean is false

Hope this helps,

 

Rob

View solution in original post

aeyzat
Occasional Contributor

Re: Delete list items not present in the data hub

Thank you for you answer, it's clear,

 

Just one more question , How i can create an action that clears the boolean in the SYS module ? I can't see this type of action

 

 

rob_marshall
Moderator

Re: Delete list items not present in the data hub

@aeyzat 

 

For the Boolean, set it to false, so you are "clearing" all true values.

 

Rob

View solution in original post