August 28, 2009 at 2:51 pm
Dear friends,
I have a ETL job that generate a text file ( with timestamp. ABCfile041208.txt).
and I would like to create a send email task to send this file as an attachement.
How can I do this? the file name is going to change everyday..
Can you show me some example?
I appreciate your help.
Thanks
August 28, 2009 at 5:37 pm
Assign the file name to a variable and use the variable in setting up the email attachment.
For best practices on asking questions, please read the following article: Forum Etiquette: How to post data/code on a forum to get the best help[/url]
August 30, 2009 at 8:53 am
Alvin,
I appreciate your reply. Thank you. I planned to do that. I am using expression to create my filename with hhmm.txt. Can you explain me in detail how to assign to a variable.
Thanks
August 30, 2009 at 9:02 am
If you're using an expression for creating the file name, try using the same expression for the attachment.
For best practices on asking questions, please read the following article: Forum Etiquette: How to post data/code on a forum to get the best help[/url]
August 30, 2009 at 9:12 am
Alvin,
My concern is if my dataflowtask executed at 11 hour and 07 mins (11:07) i.e., at filename200908301107.txt and jumped onto email part at 1108. Email expression will try to look for 11 hours and 08 mins file i.e., 200908301108.txt and cannot be found right? Because the file we geerated is 200908301107.txt.
Sorry If I am confusing you.
Thanks
August 30, 2009 at 11:32 am
you only need to use the expression part once. create a variable - call it something like outputfile - which you can evaluate as an expression. then use that variable for your data flow task output, and also use the variable as your attachment on your mail.
Viewing 6 posts - 1 through 5 (of 5 total)
You must be logged in to reply to this topic. Login to reply