Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
Bedrock Mission!

Learn more

View all

Sign in to view all badges

The 4th edition of the Campaign Community Lens newsletter is out now!
SOLVED

How to compare data originating from 2 different transitions?

Avatar

Level 7

Hello Everyone,

I have a requirement where I need to compare data from 2 different transitions and take the last modified record. Example: 

Transition A has details as below:

ID|Name|Type|Last Modified

1001|ABC|Book|20-01-2023 19:57:00

1002|ABC|Book|20-01-2023 18:30:00

Transition B has details as below:

ID|Name|Type|Last Modified

1001|ABC|Book|20-01-2023 20:30:00

1002|ABC|Book|20-01-2023 11:00:00

Now my goal is to compare this data on ID and pickup only that record whose last modified time is latest one from 2 transitions. So, in this case, my result should be as below:

ID|Name|Type|Last Modified

1001|ABC|Book|20-01-2023 20:30:00

1002|ABC|Book|20-01-2023 18:30:00

I know we can do using JS, but I am trying to achieve this with use of Targeting Activities available. Kindly please help how can I achieve this. Thanks in advance

Regards,

Sri Bhargav

Topics

Topics help categorize Community content and increase your ability to discover relevant content.

1 Accepted Solution

Avatar

Correct answer by
Level 7

Hi @Ssb_94 ,

As you have 2 transition, In any one of the targeting activity add a segment code or create a dummy attribute 

ParthaSarathy_0-1674452990130.png

 

Join the 2 transition with Union activity

ParthaSarathy_1-1674453060522.png

 

In Union activity, Select 'All shared Columns' in Reconciliation

ParthaSarathy_2-1674453292998.png

 

In deduplication activity, Select temporary schema > Select 'ID' in identification of duplicates > Deduplication method: select method: Using an expression >

Expression: Last Modified > Keep the records with Largest value

ParthaSarathy_3-1674453429813.png

 

 

View solution in original post

1 Reply

Avatar

Correct answer by
Level 7

Hi @Ssb_94 ,

As you have 2 transition, In any one of the targeting activity add a segment code or create a dummy attribute 

ParthaSarathy_0-1674452990130.png

 

Join the 2 transition with Union activity

ParthaSarathy_1-1674453060522.png

 

In Union activity, Select 'All shared Columns' in Reconciliation

ParthaSarathy_2-1674453292998.png

 

In deduplication activity, Select temporary schema > Select 'ID' in identification of duplicates > Deduplication method: select method: Using an expression >

Expression: Last Modified > Keep the records with Largest value

ParthaSarathy_3-1674453429813.png