Hi,
I need to pick up the max value that is generated by job1, and use it in job2?
For job1 i have used KeyMgtGetNextValue('x').
for job2 can i use the KeyMgtGetMaxKey('x')?
Any ideas
Thanks in advance.
To pick max number from a job and use in another
Moderators: chulett, rschirm, roy
-
- Premium Member
- Posts: 503
- Joined: Wed Jun 29, 2005 8:14 am
Re: To pick max number from a job and use in another
Three ways that I can think of doing this -
1. Make the number a Job parameter in the Job 2 and trigger Job 2 from Job 1 and pass the paramter while triggering it.
2. Use a Hashed file/Seq File to store that value Job 1 and use the file in the Job 2.
3. Use the function KeyMgtGetNextValue.
1. Make the number a Job parameter in the Job 2 and trigger Job 2 from Job 1 and pass the paramter while triggering it.
2. Use a Hashed file/Seq File to store that value Job 1 and use the file in the Job 2.
3. Use the function KeyMgtGetNextValue.
-
- Charter Member
- Posts: 7
- Joined: Tue Oct 11, 2005 7:41 am
- Location: West Lafayette, IN
- Contact:
Re: To pick max number from a job and use in another
Use the SetUserStatus function. FUNCTION SetUserStatus(ID)adams06 wrote:Hi,
I need to pick up the max value that is generated by job1, and use it in job2?
For job1 i have used KeyMgtGetNextValue('x').
for job2 can i use the KeyMgtGetMaxKey('x')?
Any ideas
Thanks in advance.
Call DSSetUserStatus(ID)
Ans = ID
RETURN(Id)
Pass your job1's max value to user status. When you combine both the jobs ina sequence you can use the status of the first job as a value in the paramter for the second job.