dbTalk Databases Forums  

Reset Failed Status on DTS

microsoft.public.sqlserver.dts microsoft.public.sqlserver.dts


Discuss Reset Failed Status on DTS in the microsoft.public.sqlserver.dts forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Nathan Truhan
 
Posts: n/a

Default Reset Failed Status on DTS - 11-29-2004 , 08:37 AM






Hello,

I have written a couple of DTS packages that pull information from an FTP
web site to a directory on the local SQL server then imported into the
database and processed. Seems fairly simple, however. The files are placed
in the FTP server from our Mainframe, and occationally, they are 0 bytes,
which SQL cannot process properly. Also, the program I am using to download
them is called CURL, which on 0 byte files, does not actually create the
file, but still returns a successfull status.

To solve this problem, I have wrote a small vbs module that executes after a
successfull download. This module will check the download directory for the
needed files. If they are there, it returns successfull and a branch
executes that imports and processes the data and emails out a status report.
If any of the files are missing, it fails, which triggers another path, that
does not import any data, but does send out a status email indicating no
new/changed records.

This leads to a situation. Every time the VBS fails, the Job I have
scheduled to run it also fails, even though it still sends out the no data
emails and everything else runs fine.

Is there anyway I can reset the failed status back to successfull in the
step following the failed branch for the vbs module, that way if it does
still fail it was on a step following that, such as sending the email.

Thank you,
Nathan

Reply With Quote
  #2  
Old   
Darren Green
 
Posts: n/a

Default Re: Reset Failed Status on DTS - 11-29-2004 , 11:41 AM






You cannot reset the status, but by using workflow scripts you can prevent
this from happening. Here is a similar example-

How can I check if a file exists?
(http://www.sqldts.com/default.aspx?211)


--
Darren Green
http://www.sqldts.com

"Nathan Truhan" <ntruhan (AT) nospam (DOT) nospam> wrote

Quote:
Hello,

I have written a couple of DTS packages that pull information from an FTP
web site to a directory on the local SQL server then imported into the
database and processed. Seems fairly simple, however. The files are
placed
in the FTP server from our Mainframe, and occationally, they are 0 bytes,
which SQL cannot process properly. Also, the program I am using to
download
them is called CURL, which on 0 byte files, does not actually create the
file, but still returns a successfull status.

To solve this problem, I have wrote a small vbs module that executes after
a
successfull download. This module will check the download directory for
the
needed files. If they are there, it returns successfull and a branch
executes that imports and processes the data and emails out a status
report.
If any of the files are missing, it fails, which triggers another path,
that
does not import any data, but does send out a status email indicating no
new/changed records.

This leads to a situation. Every time the VBS fails, the Job I have
scheduled to run it also fails, even though it still sends out the no data
emails and everything else runs fine.

Is there anyway I can reset the failed status back to successfull in the
step following the failed branch for the vbs module, that way if it does
still fail it was on a step following that, such as sending the email.

Thank you,
Nathan



Reply With Quote
  #3  
Old   
Nathan Truhan
 
Posts: n/a

Default Re: Reset Failed Status on DTS - 11-29-2004 , 12:10 PM



Darren,

This is exactly what I needed. Thank you. I will test later and let you
know how it works.

Nathan

"Darren Green" wrote:

Quote:
You cannot reset the status, but by using workflow scripts you can prevent
this from happening. Here is a similar example-

How can I check if a file exists?
(http://www.sqldts.com/default.aspx?211)


--
Darren Green
http://www.sqldts.com

"Nathan Truhan" <ntruhan (AT) nospam (DOT) nospam> wrote in message
news:9B6C1169-06A0-425E-87D9-7E42C3C5985B (AT) microsoft (DOT) com...
Hello,

I have written a couple of DTS packages that pull information from an FTP
web site to a directory on the local SQL server then imported into the
database and processed. Seems fairly simple, however. The files are
placed
in the FTP server from our Mainframe, and occationally, they are 0 bytes,
which SQL cannot process properly. Also, the program I am using to
download
them is called CURL, which on 0 byte files, does not actually create the
file, but still returns a successfull status.

To solve this problem, I have wrote a small vbs module that executes after
a
successfull download. This module will check the download directory for
the
needed files. If they are there, it returns successfull and a branch
executes that imports and processes the data and emails out a status
report.
If any of the files are missing, it fails, which triggers another path,
that
does not import any data, but does send out a status email indicating no
new/changed records.

This leads to a situation. Every time the VBS fails, the Job I have
scheduled to run it also fails, even though it still sends out the no data
emails and everything else runs fine.

Is there anyway I can reset the failed status back to successfull in the
step following the failed branch for the vbs module, that way if it does
still fail it was on a step following that, such as sending the email.

Thank you,
Nathan




Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.