November 5, 2012 at 4:28 pm
Hello ,
Could you please give me any open ideas, i am stuck in here
in my data flow task, i have oledb source and flat file destination (using flat file connection manager)
here in above data flow, oledb source has some sql statmenet as
select '"'+ employee + '","'+ + '","'+ eid+ + '","'+ empcity + '","'+ EMPDOB + '"'
it will write to file in d:\ssis\myfile.txt
so far it is working fine now,
but now how to have filename with date and time stamp on it i.e., when the file generates
myfile 11/5/2012 16:30.010.txt
myfile 11/5/2012 17:13.010.txt
myfile 11/5/2012 18:33.010.txt
myfile 11/5/2012 19:20.010.txt
etc
how can i acheive this, could some body please assist me, or any other ideas please ....
Thaanks in advance
asitti
November 5, 2012 at 4:49 pm
While there are likely many ways to do that, one technique that has worked for me is to use a variable, a connection manager and an expression that assigns the value of the variable to the connection string for the file connection manager. You can then use a basic VB.NET script to manipulate the value of the variable. You will need to make sure to add the package variable to the ReadWriteVariables parameter on the Script Task Editor.
The code to set the variable is as simple as follows: Dts.Variables("User::var_PackageVariable").Value = "Example of setting a package variable through code".
If you can provide a sample, I can probably whip something out for you to look at.
November 5, 2012 at 4:59 pm
Thank you george, for your input
mean while i am going with this
thanks again for your immediate response george, i geratfult o yy
Viewing 3 posts - 1 through 2 (of 2 total)
You must be logged in to reply to this topic. Login to reply