UD Restructure

SimonEx
New Contributor

Hi

I am looking for a way to restructure a part of our UD1 hierarchy but there over 1,600 lines to move so I don't really want to copy and move them individually to their new locations.

Is there a way to upload the new structure and overwrite the old one, or a faster way of copy/move the base levels.

Thanks

Simon

2 REPLIES 2

JackLacava
Community Manager
Community Manager

There are a few approaches:

  • Extract the metadata as XML, edit it with some scripting (Powershell, VB.net, C#, Python, etc), and upload it back
  • Use a one-off extender rule, triggered via a Data Management job. The API function to modify relationships is SaveRelationshipInfo, search across the forums for examples.
  • There are some Excel-based helpers for metadata management floating around in the wider community. I expect that sort of process might still be pretty painful over 1600 members...

Whatever you do, remember that data is stored against base members; so don't remove those, don't turn them into parents, and don't leave them orphan. Also keep an eye on constraints and channels, if you use them in combination with UDs.

Sweez
New Contributor III

@JackLacavasummarized your option well. I have reorganized some large (~5,000 members) UD hierarchies recently and did it by modifying the XML manually (Notepad ++). Here are my steps that can be modified for your situation:

1) Use Excel to create the relationship lines to move base entities to temp parent and load.

<relationship parent="Temp_Parent" child="Base1" aggregationWeight="1.0" />

2) Export relationship metadata to be replaced. Add Action="delete" to each relationship and load back into OS. This should remove the old hierarchy, while keeping the base members in a temp location.

<relationship parent="Old_Parent" child="Base1" aggregationWeight="1.0" Action="delete"/>

3) Load new hierarchy

4) Remove relationships under the Temp_Parent member direction in the dimension hierarchy.

5) Delete "Temp_Parent" member

Please sign in! SimonEx