Solved

Setting DTS FTP SourceFileName property with Dynamic Properties task

Posted on 2004-03-30
7
592 Views
Last Modified: 2010-07-27
Using a DTS package I am working on the ability for a client to upload a file to the web server. From the SQL server the DTS package will FTP the file from the web server and then pump the text file data into a table that will be used to verify data in another database table.

I am having difficulty setting the SourceFileName property for the FTP task in a DTS package. I believe I am using the correct format to set the property. Below is the SQL querry used in setting a global variable inside of a SQL Execute Task (SourceFileName).

SELECT TOP 1 OrgID,
 ''''+VerifyFileName+''''+';''e:\webs\dev.10kaday.com\admin\VerificationFiles\'';''50''' as SourceFileName,
 'e:\files\10kaday\VerificationFiles\'+VerifyFileName as DestinationFileName,
 'e:\files\10kaday\VerificationFiles'  as DestinationDirName
FROM tblVerifyOrgData
WHERE Complete <> 1

The global variable is then used in a Dynamic Properties task to set the SourceFileName property of the FTP Task. All Tasks are serially connected with On Completion Work Flow type.

The FTP task completes but there is no file. When viewing the property it appears to be set correctly after executing the package. The next Task fails which is a Transform Data Task that uses the Data Pump to pump data from the FTP'd text file to a db table.
0
Comment
Question by:kwallenbeck
  • 3
  • 2
7 Comments
 
LVL 14

Expert Comment

by:adwiseman
ID: 10714465
Have you attempted to execute each step 1 step at a time, and review the results of each step?  by right clicking the task in enterprise manager you can execute it manualy.  Then check that the correct results occured.
0
 

Author Comment

by:kwallenbeck
ID: 10714531
Yes, I have completed this simple check. Although I question whether this will always provide a good check since the properties of tasks are generated dynamically.

Thank you for your reply.
0
 
LVL 14

Expert Comment

by:adwiseman
ID: 10714730
After executing the dynamic properties task, or the tasks that finaly set the properties.  Go into the properties window of that task and see that it was changed correctly.
0
 

Author Comment

by:kwallenbeck
ID: 10715041
After running the DTS package I have checked the properties of the FTP Task and the properties all appear to be set correctly. I manually set the FTP and ran the package and the FTP Task did work. I looked at the properties of the manually set FTP Task against the dynamically set FTP Task properties and they appear to be set correctly with the Dynamic Properties Task.  Althought the file does not get uploaded. I'm wondering if they get set too late in the process somehow.
0
 
LVL 14

Accepted Solution

by:
adwiseman earned 500 total points
ID: 10715812
the property needs to get set as soon as possible, and the ftp connection object can not be changed once it is used once.  Your not looping, or using the ftp connection for more than this one task?
0

Featured Post

Free Trending Threat Insights Every Day

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

Join & Write a Comment

In this article—a derivative of my DaytaBase.org blog post (http://daytabase.org/2011/06/18/what-week-is-it/)—I will explore a few different perspectives on which week today's date falls within using Microsoft SQL Server. First, to frame this stu…
When you hear the word proxy, you may become apprehensive. This article will help you to understand Proxy and when it is useful. Let's talk Proxy for SQL Server. (Not in terms of Internet access.) Typically, you'll run into this type of problem w…
This videos aims to give the viewer a basic demonstration of how a user can query current session information by using the SYS_CONTEXT function
Via a live example, show how to setup several different housekeeping processes for a SQL Server.

760 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

18 Experts available now in Live!

Get 1:1 Help Now