Happy 8th birthday to the Maveryx Community! Take a walk down memory lane in our birthday blog, and don't miss out on the awesome birthday present that all Maveryx Community members get to take advantage of!
Bold Text Example

The localized versions of the Core Certification will be discontinued on September 22, 2023. To take the exam in your preferred language, please schedule it before this date. The Core exam will still be available in English at any time after September 22, 2023. If future versions of the Core Certification exam are localized, we will promptly announce their release dates.

Weekly Challenge

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

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

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


Challenge #12: Creating an HR Hierarchy

17 - Castor
17 - Castor
I just did a simple iterative macro
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. 

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.

12 - Quasar

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


Bridge Macro:
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

10 - Fireball

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

ACE Emeritus
ACE Emeritus

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

8 - Asteroid

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

16 - Nebula
16 - Nebula

Solution attached.


This is the worlkflowThis is my iterative macro
12 - Quasar

Solution attached. A very good test on iterative macro.