cancel
Showing results for 
Search instead for 
Did you mean: 

Syndicating multi-valued fields

Former Member
0 Kudos

Hi MDM experts,

I am syndicating a multi-valued field. The output data in the xml is comma delimited. Since my data also has commas, I need to change the delimiter to something other than a comma. How do I do that? I do not want to split the field.

thanks,

morgan

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi Morgan,

This requirement can be achieved easily with the combination of Split Multi-valued field and Custom Field.

Say you have 3 records for which you have values like this in multi-valued field. I am not taking here example with values has comma too as it will confuse you. So all you want here to change delimiter comma to some other value say @ as you have values which contain comma too, right?

RecordNo Multi-valued field

1 abc,ghi,rdf

2 abc

3 ghi,abc

How to do it: You should know what is the maximum multivalued assigned to one record, say maximum multivalued assigned to a record e.g. is 4. In Item Mapping tab, you right click on field> Split Multi-valued field>4. lly you can do it for upto any max multivalued as per your requirement.

Suppose multi-valued field name is MV. so you will have 4 new fields with MV, MV, MV and MV Now, Go to Custom Items tab, Add a new Custom Item say name MVC. Now for property Formula Formula |> Fields |> Select all four Fields MV, MV, MV and MV Your Formula will become look like this as shown below: <MV:mv><MV:mv><MV:mv><MV:mv> You can write anything between >< , so put @ between themas delimter, so your formula become: <MV:mv>@<MV:mv>@<MV:mv>@<MV:mv> Now double click on formula, a cursor comes now right click change from Include Name and Value to Include Value Only, do this for every field mean all 4 fields after this formula becomes like this. <mv>@<mv>@<mv>@<mv>

Now in Item Mapping Map this Custom field MVC with target field, you will have Display preview as:

Multi-valued field

abc@ghi@rdf@

abc@@@

ghi@abc@@

Since you have Formula which contains 3 @ delimiter and you don't want to have delimiter at the end @

In Destination Items, Select Target Field which is mapped with Source MVC.

Set these two properties which will always give you correct multi-valued values as desired shown below:

Multi-valued field

abc@ghi@rdf

abc

ghi@abc

Leading Characters to Strip = @

Trailing Characters to Strip = @

Please let me know if you still have any issue. Kindly revert with Result.

Regards,

Mandeep Saini

Answers (2)

Answers (2)

Former Member
0 Kudos

Hi Morgan

You can also try by creating a new field, Text large type, use an assignemnet in MDM on this field to get the same value from the multivalued field. You can also replace the commas in the assignment.

In the syndication map the new Text large field instead of the multi valued field.

Thanks

Ravi

Former Member
0 Kudos

Thanks Mandeep,

I got this to work, but unfortunately, it doesn't solve my problem. The field that I have that is mulit-valued is a lookup and I'm syndicating fields in the lookup table. I can split the field with the delimiter I want, but I can't split the fields of the lookup and I'm not able to select lookups in the custom fields.

If you can think of anything else, I'll really appreciate it. Thanks for this answer.

morgan

Former Member
0 Kudos

Hi Morgan,

The above solution i tried with Look up field (multivalued) to Lookup table only using MDM 7.1 SP3. I mean i have a field Country in main table which is multivalued look up to Flat table Countries. When you select main table as current table in Syndicator, You will have this field country which on navigation show the actual field say Name of your look up Flat table countries too. So when you do split this field this Name will also automatically split under that country field of main table. You should use this Name split field in your Formula. You can split the look up field of main table which is look up to some flat table and can select in Custom Items.

Regards,

Mandeep Saini