infor.com
concierge
infor u
developer portal
Posts
Categories
Groups
Hubs
Developer
Healthcare
Hospitality
Public Sector
CloudSuites
Aerospace & Defense (LN)
Automotive (LN)
Chemicals (M3)
Corporate (FSM/HRT)
Distribution (Sx.e/CSD)
Distribution Enterprise (M3)
Engineering & Construction (LN)
Fashion (M3)
Food & Beverage (M3)
Healthcare (FSM/HRT)
Industrial (Syteline/CSI)
Industrial Enterprise (LN)
Manufacturing (M3)
Public Sector (FSM/HRT)
Solutions
Supply Chain Management (SCM)
Human Capital Management (HCM)
Events
Groups
Your Groups
User Groups
Migrated Forums
FSM/HCM/S3 - Infor Lawson 10.x
HCM/S3 - Learning and Development
HCM/S3 - Global HR
HCM/S3 - Talent Acquisition
HR Service Delivery
Human Capital Management (HCM) - EMEA
Infor Configuration Management for Service Industries
Lawson - Business Intelligence
Lawson - Financials
Lawson - Human Resources
Lawson - Supply Chain
Lawson - Supply Chain Management
Lawson - Technology
MSCM on Landmark
About
Community News
Email Community Support
Home
Groups
FACTS - Partner Community
FACTS job streams, date ranges, and templates
salbritton
Has anyone figured out a way to flexibly handle date ranges on report parameters entry with job streams in FACTS?
For example, a customer may want to print the commissions report for each sales rep each month, so they set up a template for each sales rep, then set up a job stream that prints the report for each template created. However, the report has beginning and ending time fence inputs.
The only way I can think of handling this would be to essentially "hard code" in each report something to the effect of:
If the job stream 'ABC' is running, assume a beginning date of 'X' days prior to the current date and an ending date of 'Y' days prior to the current date.
Any clever/unique thoughts you'd be willing to share on this are appreciated!
Brad Kraft
Forsythe Associates, Inc.
Find more posts tagged with
Comments
Legacy Contributor
Not very user friendly but I have used UTLOOK to stuff "-60" in a template date field (meaning 60 days ago.) You also have to modify the report overlay to resolve that if it will be used in a JS.
Jim
slonschek
Here is some code I wrote to always set BEG_DATE$ to beginning of previous month and set END_DATE$ to last day of the previous month. This routine should go in your run proc for the given report.
30100 SET_BEG_END_DATE: ! ^100
30105 setesc 9710; seterr 9810
30107 ! will set the begin_date$ to start of previous month, will set end_date$ to end of previous month
30110 ! LOCAL ! cl 30100-30190,30110
30120 let CUR_MONTH$=dte(0:"%Mz"),DATE$=%D$
30130 while 1
30140 let DATE$=fnDTPLUS$(DATE$,-1)
30150 if CUR_MONTH$=dte(dec($00$+ath(DATE$)):"%Mz") then goto *continue
30160 let END_DATE$=DATE$
30170 let BEGIN_DATE$=hta(bin(jul(num(dte(dec($00$+ath(DATE$)):"%Y")),num(dte(dec($00$+ath(DATE$)):"%Mz")),1),3))
30175 break
30180 wend
30190 return
Make sure you have this function defined somewhere in your program:
18072 def fnDTPLUS$(F_D1$,F_DAYS)=hta(bin(dec(ath(F_D1$))+F_DAYS,3))
Important Links
Community Hubs
Discussion Forums
Groups
Community News
Popular Tags
CPQ: Ask a Colleague
FAQs, How-To, and Best Practices
Idea
Infor OS Portal
UI Design
CPQ: Tips and Tricks
Infor Homepages
Widget Development
Infor EPM Migration
Infor Ming.le