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

Alteryx Designer Desktop Discussions

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

Fields repeating after every Nth Field number

Chirag_KRCPL
8 - Asteroid

Given below is the dataset. Kindly note that the dataset has been shared horizontally i.e. same field repeats after every 3rd filed (although the field names are different - but as we can see below, based on the data that each field represents, one can infer the similarity in the fields (eg - field name -> 1, 4 & 7 imply same meaning)

Chirag_KRCPL_4-1657271250091.png

 

 

This is the outcome that I am expecting (but subject to an IMPORTANT NOTE specified below this snip):

Chirag_KRCPL_5-1657271279059.png

IMPORTANT NOTE

I want to make sure that workflow is dynamic enough to capture the data from new fields that would get added with similar pattern going forward i.e. in essence, same filed repeating after every 3rd field (Eg: when new fields are added  as 10, 11, 12; then field 10 will imply same meaning as field 1,4 &7....& so on) 

I have attached the excel sheet for reference.

Thanks in advance!

4 REPLIES 4
DataNath
17 - Castor
17 - Castor

How does this look @Chirag_KRCPL? It should be fully dynamic as the data is transposed and a repeating 1-3 count is applied to all values that come through. Workbook attached - let me know if you have any issues!

 

DataNath_0-1657273337159.png

 

Emmanuel_G
13 - Pulsar

Hi @Chirag_KRCPL;,

 

You can find a test with desired output. 

 

Really simple to use.

 

It works even if you have more 3 fields for each line.

 

Let us know if it works as you want.

 

Emmanuel_G_0-1657277772194.png

 

DavidP
17 - Castor
17 - Castor

Hi @Chirag_KRCPL 

 

I used a similar idea to @DataNath, but tried to do it without multi-row formulas.

 

You have to define a value for N and I included a RecordID tool so that you're not relying on the field names to be numbers.

 

You can then use the Mod() and Ceil() functions to define the column and row numbers before using the CrossTab tool.

 

DavidP_0-1657273931644.png

 

Chirag_KRCPL
8 - Asteroid

Thaknyou @DavidP @Emmanuel_G @DataNath for your response!!

Labels
Top Solution Authors