How to Scheduling and Running SQR from Peoplecode

Description
Peoplecode provides functions like CreateProcessRequest that allows us to create a ProcessRequest object.  Once this object is created, we can assign values to its properties and then use the Schedule method to submit the process request for scheduling.The CreateProccessRequest function takes 2 arguments. The Process Type and the Process Name.
/*Variable declaration*/
Local ProcessRequest &MYPrcsRqst; 
Local String &MySQR;

&MySQR = "InsTmpTbl"

/* Creating Process Request Object*/
&MYPrcsRqst = CreateProcessRequest("SQR Process", &MySQR);

/*Specifying the runcontrol id*/
&MYPrcsRqst.RunControlID = "BATCH"

/*Specifying the output option*/
&MYPrcsRqst.SetOutputOption("Web", "PDF", "", &MySQR); 

/* Use the Schedule() method to Schedule the SQR.*/

&MYPrcsRqst.Schedule();
If &MYPrcsRqst.Status = 0 then
/* Schedule succeeded. */
Else
/* Process (job) not scheduled, do error processing */
End-If;

SHARE

peoplesoft

  • Image
  • Image
  • Image
  • Image
  • Image
    Blogger Comment
    Facebook Comment

2 comments:

  1. I recently came across your blog and have been reading along. I thought I would leave my very first remark. Nice blog. I will keep visiting this blog very often. I really have to say thanks
    Terrific info on SEO, thanks for posting Day 8 |!
    This domain seems to recieve a great deal of visitors. How do you advertise it? It offers a nice individual spin on things. I guess having something useful or substantial to post about is the most important thing.
    How is it that just anybody can publish a weblog and get as popular as this? Its not like youve said something incredibly impressive more like youve painted a pretty picture above an issue that you know nothing about! I dont want to sound mean, right here. But do you genuinely think that you can get away with adding some fairly pictures and not really say something?
    obst und gemüsereiniger

    ReplyDelete
  2. uperb source that you are offering and you provide it away for free of charge. I love seeing web sites which comprehend the importance of furnishing a top quality resource for absolutely free.
    You made severalshopbymark

    ReplyDelete

Phaniraavi@gmail.com