Hold all batch jobs

 

To hold all batch jobs.


  • Create a new Job 
  • Add below code to job and execute.
  • All the batch jobs with status waiting will be changed to hold.

    BatchJob job;
   
    ttsBegin;
    while select forUpdate job where job.Status == BatchStatus::Waiting
    {
        job.Status = BatchStatus::Hold;
        job.update();
       
    }
    ttsCommit;

Comments

Popular posts from this blog

AX 2012 DEVOPS Build, Release setup and configuration

AX 2012 Build process using AZURE DEVOPS

What is Microsoft Power Platform?