Record Reference to a sub element in a Record

I’m sorta new to WM so please forgive me if there is some fatal flaw in this request …

Say my record contains various sub elements. I can create record references to the top level element but is there a way to create a record reference to sub level elements without having to create separate record/schema pairs for the sub-elements?

It would be nice because then if I changed the parent Record, the other sub-element references would be updated.

Thanks for any thoughts,
Mike

Hi, Mike. If I understand you properly, it sounds like you are trying to avoid the ideal solution by giving yourself more work!

Supposing that you have the following XML structure:

 
     
        value1 
        value2 
        value3 
     
     
        value1 
        value2 
        value3 
     

By creating records that represent the elements SubNode1 and SubNode2, the record RootNode can include them as Record References. Then, every update to either SubNode element will be reflected in your parent node RootNode.

So, to reverse your “it would be nice” statement: To update the children will – by reference! – update the parent.

Thanks for the tip! I need to rework my schemas so all the elements are top level records and the sub records are referenced and nested inside the higher level nodes.

Having good schema design will definitely cut down on the development time of the flow scripts.

I have a problem almost similar, i want to parse a flat file to a xml, but the odd lines go to SubNode1 and even lines to SubNode2.

Any idea ??

Thanks in advance

Antonio, can you be more clear in what you are trying to do? You are trying to take all odd lines from your inbound XML document and map them to a particular subnode while all even lines map to a different subnode of the same document?

Did I get that right? If so, can you please provide some examples of your XML document and anything else you deem relevant? Remember that “<” and “>” characters will not show up in your response so please use the Board Formatting tips for formatting.

Thanks.

Supposed i have a flat file like this:
BP1PSLPROVEEDORUNO003003
PB2PSLPROVEEDORUNO004004
BP3PSLPROVEEDORUNO003003
BP4PSLPROVEEDORDOS003004

where BP equal to and PB equal to

to result an xml document like this one:



BP


PB


and if you see, i need to take take one odd line with one even line and make a parent element, and do this with all my input flat file

I hope i could explain it
Thank again