DTS Package won't execute VB app under scheduler

  • Hi,

    I've got a DTS package which is executing a VB application. When manually executing the package, it will operate a-ok, however when scheduling it as a job, it runs, then hangs. The vb app has been started (checked under Task Manager), but isn't running.

    I've checked the process owners for SQL; I've tried with everything set to system account, as well as trying to run everything under my own account. I've also tried to execute the VB app under NT's "at" scheduler, with the same results.

    My feeling is that the VB app is the issue here (maybe needs special shell commands?), although I am confused as to how it runs with manual intervention.

    Appreciate any help,

    System Spec: NT 4.0 & SQL Server v7.0

  • Hi, In the vb app you should return 1 in the error handling, this way the job knows that the vb failed and you can investigate why. (If you do nothing always 0 is returned even the app failed).

    Hope this helps

    Klaas-Jan

  • I didn't create the app (and I fear there is no source either to check), so unfortunately I can't modify it.

    However, I did have a breakthrough with the debugging. I issued the "/INTERACTIVE" option with NT's "at" scheduler, and received an error message from the application. It appears that installation for the app was done under a user login (hence manual execution is fine), and when "at" scheduler runs, it operates under the system account. The end result is missing registry keys in order to execute the app. Haven't fully sorted the issue yet, but at least I have a starting point.

  • I had similar problems. One thing you might try, is have the scheduler start a bat file and have the bat file start the vb app. It's not very elegant, but it solved my problem.

  • quote:


    ...have the scheduler start a bat file and have the bat file start the vb app....


    I had to do the same thing as jbooy with a terminal emulation package I was having a DTS run. The emulation was fully scripted and required no intervention but I couldn't get it to start. Like jbooy, I had the DTS start a bat file and then had it start the application. Part of my problem was also that the program had to be started from 'within' the directory it was located in. I did the cd commands in the bat file and then started the program. Like jbooy said, not very elegent but it works. My job has been running everyday for 3 years now first WinNT/SQL7 and now on Win2K/SQL2K.

Viewing 5 posts - 1 through 4 (of 4 total)

You must be logged in to reply to this topic. Login to reply