January 6, 2012 at 4:43 pm
Hi all
I am trying to capture sysdate in a variable and then use this variable further in the package.
I have one execute sql task which is connected further to data flow task.
In execute sql task:
Insert into logging (sysdate)
Now after that in data flow task, i am using a oledb source which extract data from oracle.
select * from table1 where timestamp between max(tmstp) and sysdate.
I dont want sysdate in the above query as it changes every second. I want to get the same sysdate that was used in execute sql task fro logging purpose. Can we store that value in a variable and if so, can we use it the above query.
Thanks
Harjinder
January 6, 2012 at 4:45 pm
Yes you can do that. This article shows how to do that as well.
http://technet.microsoft.com/en-us/library/ms140355.aspx
Jason...AKA CirqueDeSQLeil
_______________________________________________
I have given a name to my pain...MCM SQL Server, MVP
SQL RNNR
Posting Performance Based Questions - Gail Shaw[/url]
Learn Extended Events
Viewing 2 posts - 1 through 2 (of 2 total)
You must be logged in to reply to this topic. Login to reply
This website stores cookies on your computer.
These cookies are used to improve your website experience and provide more personalized services to you, both on this website and through other media.
To find out more about the cookies we use, see our Privacy Policy