Extract Date information from filename

More
13 years 1 month ago #918 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

Please Log in or Create an account to join the conversation.

More
13 years 1 month ago #919 by admin
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

Mike
ETL Architect

Please Log in or Create an account to join the conversation.