- Posts: 1
- Thank you received: 0
Extract Date information from filename
13 years 1 month ago #918
by mwarnre
Extract Date information from filename was created by mwarnre
Hello Everyone:
I need to extract date information from a filename and place it into a variable. is it possible to do this? The filename is in the following format: strDDMMYYYY.csv
any help would be appreciated
thank you
mike
I need to extract date information from a filename and place it into a variable. is it possible to do this? The filename is in the following format: strDDMMYYYY.csv
any help would be appreciated
thank you
mike
Please Log in or Create an account to join the conversation.
13 years 1 month ago #919
by admin
Mike
ETL Architect
Replied by admin on topic Re:Extract Date information from filename
I guess by variable you mean a database field or File Column
First of all you need to get file name for the data reader
Reader parameter transformation function will do it for you
Than you need to get rid of '.csv' and 'str' parts of file name
Use EnsureNoPrefix and EnsurenoSuffix transformation functions
If you are loading the data into date field you should use Data format function
If you are a complete beginner watch out online tutorials first
Peter
First of all you need to get file name for the data reader
Reader parameter transformation function will do it for you
Than you need to get rid of '.csv' and 'str' parts of file name
Use EnsureNoPrefix and EnsurenoSuffix transformation functions
If you are loading the data into date field you should use Data format function
If you are a complete beginner watch out online tutorials first
Peter
Mike
ETL Architect
Please Log in or Create an account to join the conversation.