Debbie, Greg’s idea is awesome, but unfortunately we only have an outside FTP software that can be run in batch that does not have errors that toad recognizes. Basically, if there is a timeout issue, toad does not recognize that the connection issue is an issue from the batch file and continues with operation as if no problem existed.
Therefore, I really think a “retry” option for the ftp action feature would be incredible. I can see it being something a lot of folks utilize with connections that may have timeouts, especially like my company who sends so many files to different outside sources each day.
***BUT, with that said, I actually think I have a solution that virtually mimics a retry in TDP. As you know, there is an issue with #_ACTIVITY_RESULT# not showing anything in a variable if the previous action was a success. I believe that’s something they are going to try to work on. Therefore, I did further research and found that the Run Automation Script action has a return code variable that will bring back a result of that action on success or failure (0 on success and 111 or 999 on failure). Therefore, what I did was set up the FTP activity in its own stand alone task. I then took my task that is fixing to call the FTP and created a While Condition action. Before that action I created a simple variable of 111 called something like VAR1, which is the error code that comes back if the action does error. Then on the While loop action, I had it evaluate that expression of #VAR1# <> 0, then placed the run automation script activity that calls up the ftp action. Lastly, under that, I have a set variable value action that essentially goes and replaces the VAR1 variable after runtime with the return code variable of the action that was ran. So if it succeeds the first time, it will start because the first variable was an error that I made and run through the action to run the ftp. Then if it succeeds, it will bring back a result of 0, then replace the VAR1 with 0, which ends the loop and it moves on successfully. If the action does error out like with a timeout, it will come back with the 111 and essentially go through the while loop again and try again. Of course you can make that while loop have a limit of whatever before it officially ends with error, or actually works. But hopefully the 2nd or 3rd time of running it will bring back success which discontinues the loop and has the successful ftp upload.
Anyways, I thought that was something I would share. I did some testing and it seems to work great doing this way, plus it keeps me using the existing FTP action in TDP rather than having to call up an outside FTP program, so I like that as well.
Again, I’d still love the retry, but folks are welcome to try this if they need to in the meantime.