cancel
Showing results for 
Search instead for 
Did you mean: 

Why does segmentation based on attribute value produces wrong result in SAP Marketing Cloud ?

boudhayan-dev
Employee
Employee
0 Kudos

------------------Check UPDATE note -----------------------------------

Hi,

I have created a custom Marketing attribute Category in Marketing attribute Category app called - RISK_VALUE. I have created 4 contacts having values - 5,7,15 and 20 for the Marketing Category using the ODATA batch endpoint(API_MKT_CONTACT_SRV).

In the segmentation app I have selected Marketing_Attribute_Category as the attribute for segmenting the total Customer list and I have successfully received the 4 customers having RISK_VALUE as the attribute.

The problem arises after this.

Now I want to further divide this segment into 3 sub division -

  1. Range 0-12 = Segment 1
  2. Range 13-19 = Segment 2
  3. Range 20-100 = Segment 3

So I select Marketing_Attribute as the attribute for segmentation and apply the following filters to create the sub division. However, the resulting segments contain wrong values.

The following contains results for Range 20-100

1. Creating range for Segment3 i.e 20-100

2. Resulting Segment

As you can see, the resulting sub segment contains 15 along with 20. Why is this happening ? Shouldn't it just contain 20. I receive similar wrongly formed segments for the other 2 ranges as well. See below for reference.

1. For Range 0-12. Segment1

Resulting Segment

2. For Segment 2 i.e. Range 13-19. This works fine as follows

Resulting Segment

The segment2 contains proper values.

Attaching the RISK_VALUE attribute category definition for ref :

Please help.

Regards,

Dev

Update:

So, I tried to sort the listed values in the table view below in ascending/descending order. But it listed them randomly. So, I believe the values are not numeric. Instead are being listed in the order they were created in the system. How do I make them numeric for defining range on them ?

Accepted Solutions (1)

Accepted Solutions (1)

former_member197728
Active Participant

Hi Boudhayan,

Marketing Attributes are key-value pairs and the data type for the Marketing Attribute value is always NVARCHAR (length 255).

This means that they are good fits for storing character-based content (text) but are not for numeric values. Sorting or defining ranges on character-based content might produce unwanted results.

My recommendation for your use case (risk value per customer) is to switch to scores. Score values can also be imported from an external system via the API_MKT_SCORE_SRV API [1]. The problems you are having with sorting and segmenting on values should disappear.

Please mark your question as answered, if my comment helped.

Best regards,

Tim

[1] https://api.sap.com/api/API_MKT_SCORE_SRV/resource

boudhayan-dev
Employee
Employee
0 Kudos

Hi Tim,

Can I assign Score as a Marketing attribute for all the Contacts that I'll create via the Odata endpoint?

Also is it possible to provide any link as to how to link it with a contact. The end goal I am trying to achieve is - Set this score for every new Contact that I create using the OData endpoint and then use that score as a threshold in my segmentation model.

former_member197728
Active Participant

Hi Boudhayan,

yes, you can assign a score value to each contact you are creating. You will then be able to select contacts in segmentation based on the score values.

In addition to the API docu above, this is another asset: https://help.sap.com/viewer/0f9408e4921e4ba3bb4a7a1f75f837a7/1811.500/en-US/12ca1c61d9ac492195dbb6d7...

Hope this helps!

Best regards,

Tim

Answers (0)