Advent of Code is now back for a limited time only! Complete as many challenges as you can to earn those badges you may have missed in December. Learn more about how to participate here!
Start Free Trial

Alteryx Designer Desktop Discussions

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

Match positive and Negative Amounts

BRRLL99
11 - Bolide

Hi Team,

 

I have following amounts

 

dateTypeAmount
16-AprNRFB-100
16-AprMC Prsnts100
16-AprMC Prsnts100
17-AprNRFB-100
16-AprMC Prsnts100
16-AprNRFB-200
16-AprMC Prsnts200

 

Expected Output :
Date should be same with positive and negative amounts and Negative type should be NRFB and Positive should be MC Prsnts

 

dateTypeAmount 
16-AprNRFB-100Match
16-AprMC Prsnts100Match
16-AprMC Prsnts100 
17-AprNRFB-100 
16-AprMC Prsnts100 
16-AprNRFB-200Match
16-AprMC Prsnts200Match
4 REPLIES 4
Hsandness
8 - Asteroid

@BRRLL99 ,

 

You can use a multi-row formula tool to solve this. See the attached screenshot for the setup and let me know if you have questions.

Hsandness
8 - Asteroid

Here's the workflow.

BRRLL99
11 - Bolide

Already tried with Multi row formula looking for more dynamic solution

 

@DavidSkaife @binuacs @Qiu : Please provide some dynamic solution without multirow formula

Hsandness
8 - Asteroid

I created an iterative macro if you don't want to use the multi-row formula tool. I'm curious to see what the other three come up with because an iterative macro, at least mine, is more complex than just using the multi-row formula tool.

 

I added additional tests and they all passed based on the requirements.

 

 

Labels
Top Solution Authors