Job is not in the right state (compiled and not running

A forum for discussing DataStage<sup>®</sup> basics. If you're not sure where your question goes, start here.

Moderators: chulett, rschirm, roy

Post Reply
caola
Participant
Posts: 10
Joined: Tue Jul 24, 2007 3:42 am

Job is not in the right state (compiled and not running

Post by caola »

Hi all

My MainSequence job is like:

StartLoop------->Invoke JobSequence1------>Invoke JobSequence2---->EndLoop


JobSequence2 is multi-instance, and each time the same instance is invoked within the loop. I choose "Reset if required then run" when invoking JobSequence2. And the trigger is set as "Unconditional", so no matter if JobSequence2 finish/abort, it will go to next cycle.

I got below weird error randomly in MainSequence when trying to start the JobSequence2 multiple times.

MainSequence..JobControl (DSPrepareJob): Attempting to reset failed job JobSequence2.instance1
MainSequence -> (JobSequence2.instance1): Job reset requested
MainSequence..JobControl (DSRunJob): Waiting for job JobSequence2.instance1 to start
MainSequence..JobControl (DSWaitForJob): Waiting for job JobSequence2.instance1 to finish
MainSequence..JobControl (DSWaitForJob): Job JobSequence2.instance1 has finished, status = 1 (Finished OK)
MainSequence..JobControl (@JobSequence2): Controller problem: Error calling DSRunJob(JobSequence2.instance1), code=-2
[Job is not in the right state (compiled and not running)]

It's reset, but the status is 1. Shouldn't it be 21?

I checked the status of JobSequence2.instance1, it's "Has been reset".

Has any one happened to encounter the same situation? Is there any solution?

Appreciate your help...
:)
Kirtikumar
Participant
Posts: 437
Joined: Fri Oct 15, 2004 6:13 am
Location: Pune, India

Post by Kirtikumar »

As you as you get this reply in logs, have you tried running the sequence2 manually or may be using DSRunJob? Is it working that ways?
Regards,
S. Kirtikumar.
priyadarshikunal
Premium Member
Premium Member
Posts: 1735
Joined: Thu Mar 01, 2007 5:44 am
Location: Troy, MI

Post by priyadarshikunal »

try to disable auto purge and see if the problem goes away. Please let us the know the exact version of datastage. 8.0.x has problems running multi-instance jobs with auto purge on.

A search can reveal all the information on this error as it has been answered multiple times.
Priyadarshi Kunal

Genius may have its limitations, but stupidity is not thus handicapped. :wink:
Post Reply