Results 1 to 5 of 5
  1. #1
    Join Date
    Sep 2003
    Location
    Hertfordshire, England
    Posts
    78

    Unanswered: Job Step - Operating System Command

    Hi

    Im trying to run dtsrun twice in one OSC job step e.g.

    DTSRUN /F "path to dts package" /E
    DTSRUN /F "path to dts package2" /E

    Im finding that it always runs the first line but never the second. I tried swapping the lines around and it then runs the other because tht is the first line. Again the second line won't run.

    Am I trying to do something that isn't possible?

    Neil.

  2. #2
    Join Date
    Jun 2003
    Posts
    269
    Im not sure what is problem.Try using 'go' statement as shown below.
    Code:
    DTSRUN /F "path to dts package" /E
    go
    DTSRUN /F "path to dts package2" /E
    I love cursor,though I never use it.Cos' I dont want to misuse it.
    ----------------------------------------------

    ----cheers
    ----http://mallier.blogspot.com

  3. #3
    Join Date
    Sep 2003
    Location
    Hertfordshire, England
    Posts
    78
    Just tried that and it still only runs the first line

  4. #4
    Join Date
    Jan 2004
    Location
    In a large office with bad lighting
    Posts
    1,040
    Why not let the SQLServerAgent run the DTS jobs. Then you can put each statement in a separate job step, as well as choose whether or not to run the second DTS package if the first one fails. Here is an example job step:

    Code:
     
    DTSRUN /S <ServerName> /E /N <DTSPackageName>
    /*
    /S = Server name
    /E = Trusted Connection
    /N = Package Name
    /L = Log file name
    */
    This would run under the permissions of the SQLServerAgent Service login.

    -- This is all just a Figment of my Imagination --

  5. #5
    Join Date
    Sep 2003
    Location
    Hertfordshire, England
    Posts
    78
    Ok, I will try that

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •