Problem with SSIS Variables..Please advice

  • 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

  • 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 1 (of 1 total)

You must be logged in to reply to this topic. Login to reply