Hi,
I'm working on job scheduling with HANA SPS-7 version. I watched the videos uploaded on the SAP HANA Academy and also followed the steps mentioned in the HANA Developer guide. I'm trying to schedule jobs dynamically by calling xsjs which has code for adding job schedules. For better understanding the code snippet of the called xsjs looks like:
var schedule = new $.jobs.Job({
uri : "scheduleJob.xsjob", sqlcc : "schedule.xssqlcc"
});
var jobId = schedule.schedules.add({
"description" : "add job from code",
"xscron" : "* * * * * * 59",
"parameter" : {
"jobId" : "100"
}
});
When I call this xsjs, job gets added in the "_SYS_XS"."JOB_SCHEDULES" table. However, The job doesn't get scheduled and entry is not coming to the "_SYS_XS"."JOB_LOG" table.
Interestingly, when I go to the XS Admin tool and just click on save button The same job which I created dynamically gets scheduled and i can see job logs.
Could anyone please guide what I should do for achieving a fully dynamic scheduling of jobs through xsjs call (without the need of going to the XS Admin tool) ?
Regards,
Thanisha.