I have created an SSIS package which extracts data from an Excel file and outputs the results into a table in my database.
As this package will be run on a daily basis, I need to extract only those records which has been input on the day. Thus, I have added a Conditional Split in Data Flow.
When I run the "debug" in Visual Studio, my package runs fine and it shows as a "success". However, no records appear in my SQL Server Table.
I am assuming that I am doing something wrong at the "Conditional Split" level.
My "Condition" in the "Conditional Split Transformation Editor" looks as follows:
date == GETDATE()
"date" refers to a column in the Excel File where dates have been entered in the following format: 2021-06-24
I would appreciate some help to identify the problem.
GETDATE()returns aDT_DBTIMESTAMP, so is accurate to 1/300th of a second. I doubt the data you are importing was generated at the exact time you tried to import it. Likely you need to convert the value to aDT_DATEbefore you compare. - LarnuGETDATE()does.2021-06-24 17:24:59:693and2021-06-24are not the same value. - Larnu