× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



I don't blame you. I wouldn't use it either. With the BIFs provided in RPV
IV, I see no need for this, unless you have special functionality needed.
I.e. 4-4-5 accounting periods, stuff like that.

Mark Walter
Paragon Consulting Services, Inc.
IBM Certified System i Specialist
717-764-7909 Ext. 26
mwalter@xxxxxxxxxxxxxxx
www.paragon-csi.com



"Lim Hock-Chai" <Lim.Hock-Chai@xxxxxxxxxxxxxxx>
Sent by: rpg400-l-bounces@xxxxxxxxxxxx
04/01/2008 11:33 AM
Please respond to
RPG programming on the AS400 / iSeries <rpg400-l@xxxxxxxxxxxx>


To
"RPG programming on the AS400 / iSeries" <rpg400-l@xxxxxxxxxxxx>
cc

Subject
RE: Classic Traps -- I need your input!






Just curious on the purpose of creating your own date routine?

We also have one in our system and I've never use it (A lot of
developers here uses it though). Look at the parms and you will know
why I never use it:
DATECODE A 10 1 10 Date Transaction Code
CENTURY1 S 2 0 11 12 Date 1 Century
YEAR1 S 2 0 13 14 Date 1 Year
MONTH1 S 2 0 15 16 Date 1 Month
DAY1 S 2 0 17 18 Date 1 Day
JUL100YR1 S 5 0 19 23 Date 1 Julian or 100 Year
FORMAT1 A 4 24 27 Date 1 Format
CENTURY2 S 2 0 28 29 Date 2 Century
YEAR2 S 2 0 30 31 Date 2 Year
MONTH2 S 2 0 32 33 Date 2 Month
DAY2 S 2 0 34 35 Date 2 Day
JUL100YR2 S 5 0 36 40 Date 2 Julian or 100 Year
FORMAT2 A 4 41 44 Date 2 Format
DAYOFWEEK S 1 0 45 45 Numeric Day of the Week

SIGNDIFF A 1 46 46 Difference Sign Value
(+,-,' '
YEARDIFF S 7 0 47 53 Difference in Years

MONTHDIFF S 7 0 54 60 Difference in Months

DAYDIFF S 7 0 61 67 Difference in Days

DATEERROR A 7 68 74 Error Return

CLOSEPGM A 1 75 75 Close Program Flag


-----Original Message-----
From: rpg400-l-bounces@xxxxxxxxxxxx
[mailto:rpg400-l-bounces@xxxxxxxxxxxx] On Behalf Of Francis Lapeyre
Sent: Tuesday, April 01, 2008 8:20 AM
To: RPG programming on the AS400 / iSeries
Subject: Re: Classic Traps -- I need your input!

<clip>

Anyway, the old routines were using Julian dates (ouch!), and did not
account for leap year at all (Feb. 29 simply did not exist). I came up
with four or five callable programs written in RPG IV that did all the
date calcs. All of them are still in use today (we also have a service
program version of them for use in "true ILE" programs).

</clip>

As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.