Join the Inspire AMA with Joshua Burkhow, March 31-April 4. Ask, share, and connect with the Alteryx community!

Alteryx Designer Desktop Discussions

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

Dynamic vlookup of columns based on dates

Sohdaw
8 - Asteroid

Hi,

 

I have two sets of data: 

 

Table A = Formula to provide Dates 

DescriptionT-1TT+1T+2T+3
Description

Date T-1

eg. 02-Jan-2023

Date TDate T+1Date T+2Date T+3

 

Table B - note dates change daily, starting with T-1 

Description02-Jan-202303-Jan-202304-Jan-202305-Jan-202306-Jan-202307-Jan-202308-Jan-202309-Jan-202310-Jan-2023
XXX123123123123123123123123123
YYY125125125125125125125125125
CCC345345345345345345345345345

 

How do i do a dynamic vlookup between Table A and Table B to only pick up the columns based on Table A?

 

I am unable to use a JOIN tool since LEFT Join can be T-1 but RIGHT Join will be the date eg. 02-Jan-2023 which changes daily, and i'll need to have 5 Joins. 

 

Thanks

 

1 REPLY 1
Adrian_T
Alteryx Alumni (Retired)

Hi @Sohdaw, here's one way of doing it. The idea is to transpose your values such that dates in Table B fall into 1 single column, which serves as the key column for your join. Depending on the desired output format, we can then use a Cross Tab tool to bring the dates back as column headers.

 

Sample workflow is attached as well. Hope this helps! ðŸ™‚

 

Adrian_T_0-1672737143176.png

 

Labels
Top Solution Authors