Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 Import/Export (DTS) and Replication (2000)
 Export to text file inside a trigger

Author  Topic 

AskSQLTeam
Ask SQLTeam Question

0 Posts

Posted - 2002-09-03 : 08:34:16
Andrew writes "The big picture:
As the sales team sells product, the information is added to a table. I want to place a trigger on that table to write a text file for each order. Those files will be placed on a ftp site for vendor to retrive and process. Speed is a major concern, the faster that file is placed the better.

Requirements:
The file has a fixed format. All information needed in the file is contained on a record of table that the trigger is placed on. The text file must be named using the Sale Identifier, which is also on the record.


Is this possible? The hangup I have run into is using information from the record to name the output file. Any help is greatly apprecitate.

Thanks!
Andrew"

BigRetina
Posting Yak Master

144 Posts

Posted - 2002-09-03 : 10:09:45
see this
http://mysite.freeserve.com/root/WriteTextFile.html
and check xp_cmdshell in BOL


Go to Top of Page
   

- Advertisement -