GreatLakes07
asked on
Wierd error while transfering data from FTP server using SSIS Package?
i am working on SSIS package to recieve .csv files to my SQL DB.
MY FTP server is
ftp.sql.att.com
where i can find lot of csv files but i need to pick up only the before day report file so i am using varaible to check and connect to the previous date file.For that i am using below expression
"//Call_"+
RIGHT("0" + (DT_WSTR, 2) MONTH(dateadd("d", -1, getdate())), 2)
+RIGHT("0" + (DT_WSTR, 2) DAY(dateadd("d", -2, getdate())), 2)
+(DT_WSTR, 4) YEAR(dateadd("d", -1, getdate()))+ ".csv"
The output of varaible is Call_02082014.csv
While executing i am getting below error
[FTP Task] Error: An error occurred with the following error message: "Object reference not set to an instance of an object.".
If with out using varaible if i connect directly to that .csv file SSIS task working properly but when i use varaible i am getting weird error.
Note:I cant run every day ssis package so that is the reason i cfreated varaible so it can check the date and pick up exact file..
Can any one help me to solve this issue please ..
MY FTP server is
ftp.sql.att.com
where i can find lot of csv files but i need to pick up only the before day report file so i am using varaible to check and connect to the previous date file.For that i am using below expression
"//Call_"+
RIGHT("0" + (DT_WSTR, 2) MONTH(dateadd("d", -1, getdate())), 2)
+RIGHT("0" + (DT_WSTR, 2) DAY(dateadd("d", -2, getdate())), 2)
+(DT_WSTR, 4) YEAR(dateadd("d", -1, getdate()))+ ".csv"
The output of varaible is Call_02082014.csv
While executing i am getting below error
[FTP Task] Error: An error occurred with the following error message: "Object reference not set to an instance of an object.".
If with out using varaible if i connect directly to that .csv file SSIS task working properly but when i use varaible i am getting weird error.
Note:I cant run every day ssis package so that is the reason i cfreated varaible so it can check the date and pick up exact file..
Can any one help me to solve this issue please ..
ASKER
Yes i set to TRUE.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
great
Please confirm if you have set the EvaluateAsExpression=TRUE in the variable properties