Forum Discussion
fc
2 years agoContributor
OS metadata
Hi everyone,
I have a question related to the upload of a new dimension hierarchy through an XML file.
I currently have a file excel with the whole hierarchy for each dimension that I keep updati...
- 2 years ago
fc You can setup the xml's Relationships section to "Delete" a Relationship like this:
<relationships>
<relationship parent="{parent name}" child="{child name}" action="Delete" />
</relationships>
Note that deleting the Relationships may result in Orphaning a member, which in your case is what you want. A member that is Orphaned does not lose/delete its data, so as long as you upload your new file and re-create the new Relationships, your overall data will be unaffected.
AdamB
2 years agoNew Contributor II
fc Referring to what drgerrow said above.... If you are savvy with VBA, I wrote this function to help myself quickly create the lines of xml code for deleting relationships by referencing the parent and child in the formula. You will just need to get the list of relationships in excel which could be done by extracting out the xml and parse using text to columns in excel.
Here is the code I use for generating the xml lines:
Public Function Remove_Relationships_XML(ParentName As String, ChildName As String) As String
Dim Line As String
Line = Line & "<relationship parent=""" & (ParentName) & """ child=""" & (ChildName) & """ action=""Delete"" />"
Remove_Relationships_XML = Line
Exit Function
End Function
Alvaro
1 year agoNew Contributor III
could please give more details to put in acction it? I need it in the case of delete members instead of relationships. thanks in advace.
Related Content
- 2 years ago
- 3 years ago
- 1 year ago
- 2 years ago