Hi,
I am working on a data transformation task that involves fetching data from an input CSV file then converting the data into specific a format and finally exporting the CSV file. I have created the transformation job and I am able to fetch data from a specific CSV file and transform the data.
However, now the real world situation is that I would be getting the input CSV file every 30 mins, so how can I program this process to fetch only the last modified file that contains specific string.
For instance: I have following 4 files in a folder:
Site_A_Data_201311190830.csv
Site_A_Data_201311190900.csv
Site_A_Data_201311190930.csv
Site_A_Data_201311191000.csv
So, I want the Step "CSV File Input" to open last modified file from above four files that contains string "Site".
The reason for having the constraint of opening file containing string "Site" is because the output CSV file will be saved in the same directory as well. Also, I want to add a "Send Email" step that would send email with an attachment of last modified output file containing specific string.
I would really appreciate if someone can please have a look at the attached screen shot and assist me.
Thanks.
Kettle Data Transformation.jpg
I am working on a data transformation task that involves fetching data from an input CSV file then converting the data into specific a format and finally exporting the CSV file. I have created the transformation job and I am able to fetch data from a specific CSV file and transform the data.
However, now the real world situation is that I would be getting the input CSV file every 30 mins, so how can I program this process to fetch only the last modified file that contains specific string.
For instance: I have following 4 files in a folder:
Site_A_Data_201311190830.csv
Site_A_Data_201311190900.csv
Site_A_Data_201311190930.csv
Site_A_Data_201311191000.csv
So, I want the Step "CSV File Input" to open last modified file from above four files that contains string "Site".
The reason for having the constraint of opening file containing string "Site" is because the output CSV file will be saved in the same directory as well. Also, I want to add a "Send Email" step that would send email with an attachment of last modified output file containing specific string.
I would really appreciate if someone can please have a look at the attached screen shot and assist me.
Thanks.
Kettle Data Transformation.jpg