February 14, 2008 at 5:16 am
I have simple SSIS package which i created using the export wizard and saved it.
I then open it in BIDS to add the email task. But the problem i have is that every day it names the files the same, how can i change this so i can have a date format inside the file name before emailing it.
Really am a newbie to SSIS so any help would be great.
Reagrds Lee
February 14, 2008 at 10:08 am
Check this thread for the code from one of my Script Tasks:
http://www.sqlservercentral.com/Forums/Topic443977-148-1.aspx#bm444004
You would then use the value returned from the Script Task in a File System Task to rename the file before you email it.
Hope that helps.
😎
February 14, 2008 at 10:22 am
Lynn, nice snippet, I could have used it a month ago. Now I have to go back and edit some packages to remove a SQL Task just to set a variable in the proper date time format
Marvin Dillard
Senior Consultant
Claraview Inc
February 14, 2008 at 10:35 am
MD, glad to help!
😎
February 18, 2008 at 11:26 pm
Lee Hemmings (2/14/2008)
I have simple SSIS package which i created using the export wizard and saved it.I then open it in BIDS to add the email task. But the problem i have is that every day it names the files the same, how can i change this so i can have a date format inside the file name before emailing it.
Really am a newbie to SSIS so any help would be great.
Reagrds Lee
You could take those advise above. Or if you know how to use a derieved column transformation, just type in GetDate() in the expression column. Name the derieved column name as whatever you want as well as the output of it. The datatype will automatically change to database timestamp. Do it otherwise. Now connect this transformation to your destination and now you have everydays date. Hope I made your life easier!
[font="Verdana"]Imagination is more important than knowledge-Albert Einstein[/font]
Viewing 5 posts - 1 through 4 (of 4 total)
You must be logged in to reply to this topic. Login to reply