Question : Create DTS and FTP File

I am unfamiliar with SQL (use MV db) and need to accomplish, what I believe to be a pretty simple task.

We have a web form that users fill out and submit.  Upon submission, the records are written to a MS SQL database.

Upon submission of the form, this is what I need to happen:

1. Create a formatted text file with the information from the form.
2. Then FTP this file to a ftp site.

I'm assuming I create a DTS package that does all of this and then create a trigger to execute the package upon writing the records to the DB.  But I can't find out specifically how to do this.  Please provide information on:

1. Creating the text file and ftping it using DTS (if this is the best way)
2. And then creating a trigger to execute this
3. And anything else I have missed.

Thanks in advance.

kruegerste

Answer : Create DTS and FTP File

The key is, if you somehow have a bug in the trigger, you could bring the whole system to a halt. It's usually better to "disconnect" a process such as email, DTS execution or job execution from a trigger processes.

It could also become a major performance bottleneck if the process is a long process.

You're best bet is to create a batching table where a record or records are inserted from the trigger.

Then the DTS uses the batching file to create the text file.

To generate a file, here's a good link that gives you step by step instructions:

http://www.aspfree.com/c/a/MS-SQL-Server/Using-Data-Transformation-Services-part-3-Using-the-DTS-Designer-Objects-continued/




Random Solutions  
 
programming4us programming4us