Dear Team,
I am trying to extract data from some large tables and i am looking a way to create a Batch macro input that uses variable year and month data in extracting the data.
Year format is "YYYY" while month is formatted as "MM".
Year Structure:
| Name | Selection | Operator | LowKey | HighKey | Split |
| RYEAR | I | EQ | 2024 | | True |
Month Structure:
| Name | Selection | Operator | LowKey | HighKey | Split |
| MONAT | I | EQ | 01 | | True |
The macro should dynamically change the "LowKey" values for both tables. These tables will then be joined using the union tool and then fed into another tool to extract the data. Then i want this data saved into a folder that has this structure automatically: YYYY > MM > "output.csv". If the folder doesn't exist then it should be created.
For example, if extracting data for 2022, the macro will cycle through months 01 to 12, then move to the next year in the list.
Inputs:
Years (>= 2020): Generated using the "Generate tools".
Month: 01 - 12
Many thanks in advance for your help.