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

Weekly Challenges

Solve the challenge, share your solution and summit the ranks of our Community!

Also available in | Français | Português | Español | 日本語
IDEAS WANTED

Want to get involved? We're always looking for ideas and content for Weekly Challenges.

SUBMIT YOUR IDEA

Challenge #12: Creating an HR Hierarchy

patrick_digan
17 - Castor
17 - Castor
Spoiler
I just did a simple iterative macro
Capture.PNG
MaxGiegerich
8 - Asteroid

I'm aware we were supposed to use an iterative macro here (and I will do shortly for the practice!) but I feel the following solution works just as well and is simpler. I got used the Append Fields tool to get do a cross join then used some very basic logic to massage the data into the right format. One issue was the analyst's man_id is 2 but the manager's is 1. I'd assumed these have to be in order of seniority so this is a bug in the input data. Obviously this could be corrected manually but I haven't here (as surely that defeats the purpose).

 

*My mistake... man_id is clearly the ID of their manager, not the 'paygrade' or 'level' of seniority. There's probably a way of working this out using the cross join method but I'm going to go with the iterative method as it's more interesting and efficient (I'd imagine!) anyway. 

siddhartha_s
7 - Meteor

the suggested visuals can also be obtained in NodeXL an addin for network graph... Trying to get it all in Alteryx. Thanks for your response.

JoshKushner
12 - Quasar

What a great bridge table! Wrote an iterative macro to handle the hierarchy.

 

Spoiler
Bridge Macro:
bridge.PNG
 
dsmdavid
11 - Bolide

Quite some trial and error to get my mind around the iterative macro and only because @Phil_L57 was around...Not sure I still get it... but it works

samN
10 - Fireball

Well i feel whooped. Probably not the sanest way to introduce oneself to iterative macros...

ggruccio
ACE Emeritus
ACE Emeritus

Learned a lot about iterative macros in last year's Santalytics!  This one was fun!.

LandonG
8 - Asteroid

It took a long time for this one to "click".

PhilipMannering
16 - Nebula
16 - Nebula

Solution attached.

 

Spoiler
This is the worlkflowThis is my iterative macro
jasperlch
12 - Quasar

Solution attached. A very good test on iterative macro.