Hi
Hoping someone could help advise on how to solve this in Alteryx.
I have multiple files received on a daily basis:
every Saturday - Weekly full (which is a catch all file)
from Mon-Thurs - daily delta file (anything that is newly added and had changes)
Sat - Weekly full | Mon - Daily - Delta | Tues - Daily - Delta | Wed - Daily - Delta | Thurs - Daily - Delta | ||||||||||||||
Record ID | Type | Rate | Record ID | Type | Rate | Record ID | Type | Rate | Record ID | Type | Rate | Record ID | Type | Rate | ||||
1 | EQ | 1.3 | 1 | EQ | 3.4 | 10 | FI | 3.4 | 2 | FI | 3.3 | 11 | CS | 2.3 | ||||
2 | EQ | 5.3 | 2 | FI | 5.3 | 11 | CS | 5.3 | 11 | CS | 3.3 | 13 | FT | 1.4 | ||||
3 | EQ | 2 | 8 | CS | 3.5 | 12 | EQ | 7.3 | 13 | FT | 4.4 | 14 | FI | 5.5 | ||||
4 | FI | 3.7 | 9 | FT | 3.3 | 9 | FI | 3.3 | 15 | EQ | 3.5 | |||||||
5 | CS | 4 | ||||||||||||||||
6 | EQ | 3.5 | ||||||||||||||||
7 | FI | 2.4 |
The ask is depending on the day I run the workflow will grab the latest Saturday weekly file + the daily delta file.
and if the same record ID appeared in the delta file, I just need whatever the latest data for that record ID
e.g.
If I run the workflow on Sat, Sun, Monday --- pull the latest Sat weekly file
If I run the workflow on Tues --- pull the latest Sat weekly file + latest Mon file
If I run the workflow on Wed--- pull the latest Sat weekly file + latest Mon file + latest Tues file
If I run the workflow on Thurs --- pull the latest Sat weekly file + latest Mon file + latest Tues file + latest Wed file
If I run the workflow on Fri --- pull the latest Sat weekly file + latest Mon file + latest Tues file + latest Wed file + latest Thurs file
Thank you! Any advice is highly appreciated.
@jillv ,
I guess the files have names with the creation date. If not, please consider to do so.
Then you save all the files in the week in one folder and create the workflow:
1. read all files in the folder at once, with the filename added to the table.
2. parse the date from the filename field.
3. sort the table with Record ID and File Date (Desending order).
4. pick the first row of each Record ID.
Intput Data tool configuration
Workflow
I am not sure if this can be the exact solution for you, but I hope this may be helpful.
Good luck.