Bring Segment Qualification Data from External Systems | Community
Skip to main content
pradeep_nextrow
Level 4
May 27, 2023
Question

Bring Segment Qualification Data from External Systems

  • May 27, 2023
  • 1 reply
  • 1601 views

Hello All,

CONTEXT: I am trying to bring segment qualifications from a partner into RT-CDP. The columns in their data export table looks like this - Hashed Email ID, Segment 1, Segment 2, Segment 3 .... Segment N (the qualification value is 1 or 0 depending on whether the user is in the segment or not.

Every month, there are incremental files we get. Every month the number of columns vary based on the data their team collects. Ex: This month we get 10 segments (Hashed Email ID, Segment 1, Segment 2 ... Segment 10) and next month we might get 15 segments (Hashed Email ID, Segment 1, Segment 2 ... Segment 15).

 

QUESTION: What would be best approach to model this and bring it in CDP? I also saw there was a "Segment Definition" class which is for bringing segment data from other systems (https://experienceleague.adobe.com/docs/experience-platform/xdm/classes/segment-definition.html?lang=en) but I am not sure how to use it. Any insights would be helpful. thx!

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.

1 reply

Level 2
May 29, 2023

Hi Pradeep,

 

You can Create a Individual profile class schema with the attributes required along with a field with data type "Segment Membership Details". From the source you can compose your data in the required format and ingest into the dataset. You can even try with Query services also to compose the data using Map function. But it is too hard as the segments you are thinking is dynamic in nature. 

 

"segmentmembership": {
"external":{
"segment1":{
"status":"existing",
"lastqualificationtime":"2023-05-30T10:00:00.000Z"
},
"segment2":{
"status":"existing",
"lastqualificationtime":"2023-05-30T10:00:00.000Z"
},
"segment3":{
"status":"existing",
"lastqualificationtime":"2023-05-30T10:00:00.000Z"
},
"segment4":{
"status":"existing",
"lastqualificationtime":"2023-05-30T10:00:00.000Z"
},
"segment5":{
"status":"exiting",
"lastqualificationtime":"2023-05-30T10:00:00.000Z"
}
}
}

 

sample SQL on how to use the map function. 

 

select map('externalSegments',
map('segment1',
struct (
'existing' as status,
'2023-05-30T10:00:00.000Z' as lastqualificationtime
)
,
'segment2',
struct (
'existing' as status,
'2023-05-30T10:00:00.000Z' as lastqualificationtime
)
)
)

 

Regards,

Vinod

NimashaJain
Adobe Employee
Adobe Employee
May 30, 2023

@pradeep_nextrow Did the solution worked?

pradeep_nextrow
Level 4
May 31, 2023

Hi Nimasha, Trying out this and one another approach as suggested by @vinkom. Will post this once I compete it.