Segments in Customer Insights - Journeys: multi-hop, custom tables, N:N and 1:N relationships

Segments are the magic sauce that you need to start a segment-based journey in Dynamics 365 Marketing (Customer Insights - Journeys). It’s a way of creating a data driven list of ‘members’ (contacts, leads or ‘unified profiles’ from Customer Insights - Data) who you want to send through an automated journey.

You can use segments created in outbound marketing for your real-time journeys but there are limitations that mean you have to use the real-time segment builder instead. For example, a few things only the real-time segment builder can do:

  • Target leads

  • Segment on consent, purposes or topics

  • Use interaction data from real-time journeys, forms and emails

  • Be used in a ‘Send Now’ journey without being previously used in anther manual real-time journey

  • Ensure users have a consistent (but arguably sub-par) segment building experience rather than having to learn multiple segmentation tools

Also if you don’t have outbound marketing installed then you don’t have a choice at all!

For some high level info you can check out the official Microsoft Docs on building segments in Customer Insights - Journeys which covers a few basic happy path segment stories focusing on the classic N:1 story of a Lead associated to an Account. The trouble starts when you try to create anything beyond these so lets try to wrangle the real-time segment builder into data driven submission, starting with the main problems I have come across when working with multi-hop data queries, custom tables, N:N and 1:N relationships.

Example: List all contacts where their Account is associated to an Open Opportunity

Can’t get to the thing you want to filter on

If you are used to the outbound marketing segment builder you need to throw away all the skills you learned and start again as the mental model is very different.

Previously you had to build the pathway from/to the contact yourself like this ->

Now you just need to select the end attribute you want to filter, and then select the pathway to get there. So for the example ‘List all contacts where their Account is associated to an Open Opportunity’, ignore the Account link and directly select Opportunity Status. Then select the Contact -> Account -> Opportunity pathway. Finally define which relationship to go via for each pathway (if there is multiple).

PS. When you cant find the pathway for Account - carry on reading!

‘Select a path’ not showing the pathway you want

So you went directly to the Opportunity status but now there is no option to select the ‘Account as part of the relationship? Great.

Add the opportunity to ‘Related tables’

Search in the tables to select ‘Status’ from the opportunity table - the the appropriate pathway Contact -> Account -> Opportunity - is missing, but I know this relationship exists.

WAIT, before you exit this screen, add the opportunity status into your segment via any relationship you like, even if its the wrong one. If you don’t add it to the segment, the table is going to disappear from the ‘Related tables section when we go to fix the missing account issue.

I know its wrong, its not what we want but right now we need it and will fix it later!

Now we need to add the Account table into the ‘Related tables’ as the reltionship pathway we want to use goes via the Account

However, adding the Account table into the ‘Related tables’ alone is still not enough for the pathway to show up

Add a condition that uses any Contact -> Account relationship into the segment, I know its irrelevant and we will throw it away later but trust me it’s not pointless. Basically any table that the relationship goes ‘via’ need to be included in the table list and then have a useless condition added so that it gets ‘stuck’ into the segment.

Behold your absolutely useless segment using conditions you didn’t want to use. Save it!

Refresh the page. You might need to add the Account and Opportunity tables into the ‘Related tables’ again. Select status from Opportunity into a ‘New Group’ -> ‘New Group’

Warning: try not to fall of your chair in amazement of the mysterious Contact->Account->Opportunity pathway you now behold!

Pretty amazing huh? Now you can delete the conditions from Group 1 and Group 2 and carry on with your life building segments via 1:N, N:N and custom tables!

Segment is stuck ‘Getting Ready’

“We've detected that the segment is taking longer than expected. In the meantime, you will be able to create draft journeys and emails with this segment. If you are blocked by this issue, you may contact support.“

This happens a lot with segments that go beyond the happy path, especially if its a table you have not segmented on before. I do not have a magic fix unfortunately. I usually try to wait the grace period of two hours for syncing new tables. Sometimes creating the same segment again from scratch can go straight to ’Ready to send’. Otherwise you need to raise a ticket and whinge/suffer through the ‘support’ experience. I’m sorry and I feel your pain.

The table is unavailable to be added because it ‘may be more than five hops away from the target audience.’

If your table is more than 5 hops away then I can’t help you - thats an understandable product limitation. However I often see this warning when I know for a fact it is closer than 5 hops. An out of the box example is ‘Quote Product’.

The fix is a similar approach to the missing pathway issue above, basically you need to add ‘Quote’ as a 'Related table’ then add in a condition for the quote which is completely pointless to you, save the segment to make the new relationship/related table stick.

Reload the page and proceed to add ‘Quote Product’ as a related table again - this time the mysterious 5 hops issue is resolved and you can now select the pathway you need and filter on the quote product data.

For example below you can now add attributes from the ‘Quote product table and filter contacts by those who have a quote which includes a specific product - magic!

More examples please

There are a few more posts on the way to help with some specific scenarios around Activities (Email, Appointment, Task etc.) and also with Quotes but if you have any other segments you are struggling with that my suggestions above aren’t helping, or seeing other errors that are tricky to resolve leave me a comment and inspire my next segment wrangling adventures!

Previous
Previous

Segments in Customer Insights - Journeys: Activities (Email, Appointment, Phone Call etc.)

Next
Next

Include specific row (entity) references and all the data in Real-time marketing custom triggers