× 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.



<snort>

Yeah, you and my wife agree that one me is enough >chuckle<

Anyway, here's another one: 10000.0001. Works from ccyymmdd to mmddccyy - and *back*!

Joe


I'm not Joe [thank heavens .-)] but the reciprocal was 10000.01 (I had to
look it up, guys; I don't have a cheat sheet of these anymore, really).
These only work on 2 position year fields.

I can't remember where, but there was a whole slew of these formulas
published back in the 80's. Think it was either Midrange Computing (now
defunct) or News36/38 (now System i News).

Jerry C. Adams
IBM i Programmer/Analyst
--
A&K Wholesale
Murfreesboro, TN
615-867-5070


-----Original Message-----
From: rpg400-l-bounces@xxxxxxxxxxxx [mailto:rpg400-l-bounces@xxxxxxxxxxxx]
On Behalf Of Tom Huff
Sent: Thursday, March 24, 2011 10:56 AM
To: 'RPG programming on the IBM i / System i'
Subject: RE: Question about legacy coding style

Joe, I keep forgetting, what is the reciprocal to convert it back ?

Tom

-----Original Message-----
From: rpg400-l-bounces@xxxxxxxxxxxx [mailto:rpg400-l-bounces@xxxxxxxxxxxx]
On Behalf Of Joe Pluta
Sent: Thursday, March 24, 2011 7:36 AM
To: RPG programming on the IBM i / System i
Subject: Re: Question about legacy coding style

On 3/24/2011 4:51 AM, Craig Pelkie wrote:
Thanks for all of the replies.

This type of thing always strikes me as being "programming archeology", in
that you had to be there to really know why something was done (what it is
doing is not too hard to discern, but the "why's" become dimmer over
time).
There should probably be some project launched as a wiki to collect and
document these kinds of idioms. Somebody 10 years from now won't have any
idea why this was done, and those who remember, well, they might not be on
this list. Legacy COBOL is probably the same way (to pick another widely
used language with an enormous legacy code base).
Absolutely. MULT 100.0001 has to go in there! I can't imagine anybody
but an (old) RPG programmer being able to decipher that one.

I have a couple of old 8085 assembler tricks rattling around in my head
as well<grin>.

Joe


As an Amazon Associate we earn from qualifying purchases.

This thread ...

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.