Advent of Code is back! Unwrap daily challenges to sharpen your Alteryx skills and earn badges along the way! Learn more now.

Alteryx Designer Desktop Discussions

Find answers, ask questions, and share expertise about Alteryx Designer Desktop and Intelligence Suite.
SOLVED

Merge Similar Records into One Row, SQL to Alteryx

agriese
7 - Meteor

I have a file of duplicate contact records, where I've already determined which record should be the Master and which should be the Victim(s). Unfortunately, the merge software we use for Salesforce can't compare all victims to the master and fill in any blank values. I'd like to end up with a file of Master records that need to be overwritten before the actual merges are run.

 

Input:

 

EmailLevelPhonePhone2Phone3Phone4Phone5
mary@littlelamb.orgMaster######    
mary@littlelamb.org

Victim

 ######   
mary@littlelamb.orgVictim###### ######  
mary@littlelamb.orgVictim######  ###### 
mary@littlelamb.orgVictim    ######

 

Output:

 

EmailLevelPhonePhone2Phone3Phone4Phone5
mary@littlelamb.orgMaster##############################
mary@littlelamb.org

Victim

 ######   
mary@littlelamb.orgVictim###### ######  
mary@littlelamb.orgVictim######  ###### 
mary@littlelamb.orgVictim    ######

 

I found this advice in Stack Overflow, but I don't know how to replicate this SQL query in Alteryx. Any thoughts?

2 REPLIES 2
markcurry
12 - Quasar

I think the attached workflow will give what you are looking for, using the Summarize tool to get the Max value.  I wasn't sure if you wanted the full output table, or just the first line.  Hope it helps..

agriese
7 - Meteor

That's it exactly! I was trying to use a bunch of multi-row formulas, and this is so much simpler. Thank you!

Labels