Login
Register
Search
Home
Forums
Jobs
LawsonGuru
LawsonGuru Letter
LawsonGuru Blog
Worthwhile Reading
Infor Lawson News Feed
Store
Store FAQs
About
Forums
Infor / Lawson Platforms
S3 Systems Administration
System Date in Job Parm
Home
Forums
Jobs
LawsonGuru
LawsonGuru Letter
LawsonGuru Blog
Worthwhile Reading
Infor Lawson News Feed
Store
Store FAQs
About
Who's On?
Membership:
Latest:
Saef
Past 24 Hours:
0
Prev. 24 Hours:
0
Overall:
5226
People Online:
Visitors:
320
Members:
0
Total:
320
Online Now:
New Topics
User Group Announcements
Carolina User Group Meeting
12/20/2024 3:15 PM
Date & Time: February 6, 2025, 8:30am - 4:00pm
S3 Systems Administration
ADFS certificate - new cert
12/3/2024 9:38 PM
The certificates on the windows boxes expired and
Lawson S3 HR/Payroll/Benefits
Post Tax Benefit Plan Table
11/14/2024 9:16 PM
Hi, totally new to Laswon. I have a repor
Lawson S3 Procurement
ED501 Error: Map 850 not supported by /law/c15vda/lawson/test10/edi/bin/laws_out_91
11/12/2024 3:47 PM
Tried runnning ED501 and getting the atathced erro
Lawson S3 HR/Payroll/Benefits
Error
11/6/2024 9:54 PM
When I try to enroll a retiree in 72.1 health plan
Infor ERP (Syteline)
Syteline: New Data Maintenance Wizard (Error) Need help
11/1/2024 4:24 PM
Hi, I need help with an error on syteline while us
Dealing with Lawson / Infor
Implementing Lawson v10 with Cerner Surginet, Case Cart Picking, and Quick Adds for the OR
10/29/2024 4:20 PM
Hi Everyone, I am wondering if there is any org
Lawson S3 HR/Payroll/Benefits
Canada Tax Calculation (Federal and Provincial) Issue
10/23/2024 5:00 AM
Initially, we had problem with CPP2 calculation is
Lawson S3 HR/Payroll/Benefits
CA Section 125 401k Plan
10/22/2024 10:13 PM
Does anyone have any recommendations on how to fac
S3 Systems Administration
Running AC120 deleted records from ACMASTER table
10/22/2024 3:40 PM
We recently ran the AC120 as normal and somehow it
Top Forum Posters
Name
Points
Greg Moeller
4184
David Williams
3349
JonA
3291
Kat V
2984
Woozy
1973
Jimmy Chiu
1883
Kwane McNeal
1437
Ragu Raghavan
1372
Roger French
1315
mark.cook
1244
Forums
Filtered Topics
Unanswered
Unresolved
Announcements
Active Topics
Most Liked
Most Replies
Search Forums
Search
Advanced Search
Topics
Posts
Prev
Next
Forums
Infor / Lawson Platforms
S3 Systems Administration
System Date in Job Parm
Please
login
to post a reply.
7 Replies
1
Subscribed to this topic
27 Subscribed to this forum
Sort:
Oldest First
Most Recent First
Author
Messages
Roger French
Veteran Member
Posts: 549
5/16/2007 11:48 AM
I saw an answer to this question on another board a few years ago.. but now I need to revisit it.
I want to run a daily HR155 job and the History Date is a required field. If I set up the job in jobdef and then recdef I will need to hand key in a static History Date.
How can I set it up so that for each day I run the job (scheduled through recdef) the job parameter screen will dynamically pick up the current system date and use that for the History Date? I know this question's been asked before. My initial thought is that the program will need to be modified to populate the History Date field with the current system date.
Thanks in advance for your help,
-Roger
mondrar
Advanced Member
Posts: 35
5/16/2007 10:29 PM
I want to do the same thing in LP180. Any ideas anyone...
John Henley
Posts: 3353
5/18/2007 12:27 PM
Off the cuff, I can think of three ways to do this:
1. Create a shell or perl script that calls jobdump/jobload (or ujobdump/ujobload) to dump/update the date as part of the parameters in the job definition.
2. Modify the desired job's COBOL code to change the desired date to the current system date. This introduces two problems:
a) Assumes the program is always being run as part of a recurring job; what if the program is being run for a special case and NOT as a non-recurring job and you REALLY don't want to do to substitute the date?
b) It's a maintenance headache--you now have (hopefully) a forked version of a standard Lawson program, which you have to maintain as part of CTP/MSP maintenance cycle.
3. Create a separate COBOL program that runs before the desired recurring job(s). It has as parameters the username, jobname, step#, and byte position within JOBSTP-PARAMS for the desired date. That program would PERFORM 900-LOAD-JOB, change the date, then PERFORM 900-CREATE-JOB to modify the job record. This approach is general-purpose (i.e. you can use it for many different jobs/programs) and doesn't introduce the maintenance issues with option #2.
Sam Simpson
Veteran Member
Posts: 239
5/18/2007 3:17 PM
I remember changing the .scr file and put @TD as the default value for dates. So if
the parameter field is blank then the default is the system date/time. Hope this helps.
John Henley
Posts: 3353
5/18/2007 5:47 PM
That's an interesting idea; the problem though may be that you have to do that change AFTER the recurring job is added. Otherwise the date field will be filled with the current system date on the day the job is added, and will remain that way unless you manually change the parameters field on the job definition.
Nabil
Veteran Member
Posts: 61
9/8/2016 9:24 PM
Was there any good answer to this question? We'd like to use similar functionality and didn't know if Lawson provided an easy way to code a date parameter to today's date for a scheduled batch job.
JimY
Veteran Member
Posts: 510
9/13/2016 10:40 AM
The only way I was able to do this was to modify the program to grab the system date and populate the parameter field with it. You may also be able to do it through IPA, but I have not attempted it. You might check in the Lawson Process Flow forum to see if anyone has accomplished it and posted their results.
Any ideas?
Basic Member
Posts: 20
9/15/2016 10:35 PM
There is a better way in using curl and scripting it out instead of modifying it in 4gl.
#!/usr/bin/ksh
OK="
Job Changed
"
DMPFILE='hahaha.dmp'
JOB_UID=lawson
JOB_PWD=iwonttell
SERVERNAME=mywonderlandurl
DATE=`date +%Y%m%d`
curl -A 'Mozilla Firefox/2.0.0.17' --dump-header ${DMPFILE} -d "_ssoUser=$JOB_UID&_ssoPass=$JOB_PWD&_action=LOGIN&_fromLoginPage=TRUE&_language&_ssoOrigUrl=http://${SERVERNAME}/lawson/portal/logondone.htm" http://${SERVERNAME}/sso/SSOServlet
MSG=$(curl -A 'Mozilla Firefox/2.0.0.17' -L -b ${DMPFILE} -d "_PDL=PROD&_TKN=WH110&_LFN=ALL&_RTN=DATA&_TDS=IGNORE&_OUT=XML&_EVT=CHG&FC=C&JOB-NAME=WH110&USER-NAME=$JOB_UID&COMPANY=1&LOCATION=1&ALLOCATE-DT=${DATE}&_EOT=TRUE" http://${SERVERNAME}/servlet/Router/Transaction/Erp? 2> /dev/null |grep "
")
if [[ "${OK}" = "${MSG}" ]]
then
echo "Success"
else
echo "Failed"
echo $MSG
fi
rm ${DMPFILE}
echo "Ok. Don't you think you should send a walmart gift card to the person who write this?"
Please
login
to post a reply.