community
cancel
Showing results for 
Search instead for 
Did you mean: 

Alteryx designer Discussions

Find answers, ask questions, and share expertise about Alteryx Designer.
Community v19.6

Looks aren't everything... But the latest Community refresh looks darn good!

Learn More
SOLVED

Conditional based joining two column values from different tables

Meteor

Hi all, 

 

I am new to alteryx i have a scenario of containing two tables as shown below

Table 1:

EmpTypeCity
AWorkBrazil
AHometown
ALeave 
BWorkAmerica
BLeave 
BHometown
CWorkAfrica
CHometown
CLeave 

 

Table 2 as below:

 

EmpHometown
AAmerica
BAfrica
CBrazil

 

My expected output is joining only the city's where Type is hometown in the table 1 with Hometown in table 2 and must display as 

 

EmpTypeCity
AWorkBrazil
AHometownAmerica
ALeave 
BWorkAmerica
BLeave 
BHometownAfrica
CWorkAfrica
CHometownBrazil
CLeave 

 

Anybody help in this!!!!!!!

 

Regards,

Yoganantha Prakash G P

Alteryx Certified Partner
Alteryx Certified Partner

Hi @Yoga321 

 

See solution

 

Solution100.PNG

 

- Add a Record ID to original Dataset

- Transpose lookup HomeTown table

- Join the datasets by Emp and Type = Name (Hometown records)

- Union the Left Side (no hometown records) with Join Side (hometown records) - Auto Config by Position in this case

- Sort by Record ID to put everything in order.

- Deselect Record ID

 

WF appended.


Cheers,

Highlighted
Meteor

Thanks Thableaus!!!!!

Labels