I've some months as my column name like below.
Now i'm reading first 4month at once.
APR | MAY | JUN | JULY | AUG |
1 | 4 | 5 | 8 | 10 |
2 | 3 | 6 | 7 | 9 |
Then i'm using dynamic rename to change these months like below
if contains([Current_field],'APR')
then replace ([Current_field],'APR','M1')
elseif contains([Current_field],'MAY')
then replace ([Current_field],'MAY','M2')
elseif contains([Current_field],'JUN')
then replace ([Current_field],'JUN','M3')
elseif contains([Current_field],'JULY')
then replace ([Current_field],'JULY','M4')
endif
Now i want to change these months dynamically. Like next time it should start with MAY,JUNE,JULY and AUG
Is it possible to change the above calculation dynamically so that it keeps on taking
I would still use the dynamic rename, but use a positional rename and feed the M1, M2, M3, M4 values in via a text input. This way no matter what the first 4 columns are they get renamed accordingly. You can then go further and use a dynamic select to look for just these fields with the naming convention of M#
Here is my take on this just adding another option.
Workflow:
I do agree with @Luke_C approach. It is a good strategical approach.
Hope this helps : )