Focal Point
Nextruntime value for a completed Schedule ?

This topic can be found at:
https://forums.informationbuilders.com/eve/forums/a/tpc/f/7971057331/m/1351067862

January 29, 2008, 03:47 PM
<Navin>
Nextruntime value for a completed Schedule ?
Hi

Can anyone tell me what will be the the nextruntime value that will be set for a completed schedule that is scheduled for only one time.
January 29, 2008, 04:50 PM
Prarie
I believe it is - Never


In Focus since 1993. WebFOCUS 7.7.03 Win 2003
Navin -

In an earlier post here

you found the RC equivalent of Prarie's 'never.'


jimster06
DevStu WF 7.6.11
W7
HTML, PDF, EXL2K
Never is the correct answer, but there is obviously another question which is what do you want it to be? If you are wanting the job to run again, you can change the date (or time) and schedule it again or you can just right click and run.


Pat
WF 7.6.8, AIX, AS400, NT
AS400 FOCUS, AIX FOCUS,
Oracle, DB2, JDE, Lotus Notes
Hi

Actually i am not trying to rerun the job. But i am extracting the nextruntimevalue from BOTSCHED to a front end where i am showing a list of schedules and its nextruntime value.

In this list , all the schedules that are yet to run are showing a correct date of when it will be running.

But when any schedule is completed , then the query is throwing an error saying the "year has to be between 4713 and 9999 and never be 0"

The query i am using is ,

select scheduleid , nextruntime from botsched ;

when i examined the nextruntime value for a schedule that got completed , it was set as '00000000000009223372036854775807'.

so applied the following conversion over the nextruntime for seeing the date.

select TO_DATE('01/01/1970','MM/DD/YYYY')+((((to_number('00000000000009223372036854775807'))/1000)/(60*60*24))-8/24) nextrun
from dual.

it again gave the same error message.

So is there anyway that i can run a select query over BOTSCHED for retreiving the nextruntime for a all the schedules (including the finished and yet to run schedules).


Thanks
Naveen
You are in an area where I have no experience, but if it is only the "Never" that are giving you a problem, try selecting those schedules that are not equal to '00000000000009223372036854775807' converting to your date/time and union them to those that are equal to '00000000000009223372036854775807' setting that to a date/time that is a default value ('01/01/1970 00:00:00').

By the way, what is the error message you are getting?


Pat
WF 7.6.8, AIX, AS400, NT
AS400 FOCUS, AIX FOCUS,
Oracle, DB2, JDE, Lotus Notes
Actually the reason is , the NEXTRUNTIME will be encrypted and stored for the schedules that are completed.That value can only be read by the distribution server . We should not apply our usual logic for retrieving the nextruntime value for the completed schedules.

SO i did a decode() function in my oracle query so that i get no error .
like,
(decode(b.nextruntime,'00000000000009223372036854775807','00000000000000003372036854775807')

So in the front end upon interpreting this i can handle it as completed