This one app in specific broke some pretty standard MV rules, the dates
being one of them. It was started in Oct 1974, going on-line in the summer
of 1975 and these guys were still working on it through 1978. Since then,
there have been a parade of around 3-4 other programmers as well as the
owner who dabbles in basic & proc. I started with them in 1997

One of my favorite phrases applies. "Nothing is completely worthless, It can
always serve as a bad example."

>From my educated retro-viewing of this code, I can conclude that they didn't
even know of ICONV for dates. There were old-school, "30 days hath
september" logic as well as a totally SNAFU'd invoice line item file. Don't
get me started on how they interpeted record locking using LOCK and process
locking using control file records.

Some of the examples of extremely poor code are:

reading:
READ REC FROM FILE, ID
MAT ALL=""
FOR I=1 TO 40 ; ALL(I)=FIELD(REC,CHAR(254),I) ; NEXT I

writing:
Z=CHAR(254) ; Y=CHAR(253)
REC=CUSTNO:Z:ORDN:Z:AMT:Z:Z:Z:Z:Z:Z
BBB=DATEANS
REC=REC:Z:Z:Z:BBB
REC=REC:Z:Z:A:Y:B:Y:C:Z:TOTALPRICE
WRITE REC ON FILE, ID

I swear on a stack of bibles that I'm not making this up.

Mark Johnson
----- Original Message -----
From: "Allen E. Elwood" <[EMAIL PROTECTED]>
To: <[email protected]>
Sent: Friday, September 02, 2005 2:48 PM
Subject: RE: [U2] Date ICONV In English


> >It isn't that ROFLOL
>
> I'm still snickering about it...in 31 years of programming I've never seen
> anyone store a date in external format.
>
> I get all giggly just thinking about it.
>
> I had a hard time stopping just to type this message.. :)
>
> -----Original Message-----
> From: [EMAIL PROTECTED]
> [mailto:[EMAIL PROTECTED] Behalf Of Mark Johnson
> Sent: Friday, September 02, 2005 11:35
> To: [email protected]
> Subject: Re: [U2] Date ICONV In English
>
>
> It isn't that ROFLOL, rather there are situations where human dates are
> stored in text fields and can be dissected out.
>
> I did have one client's app (circa 1974) that I still support today that I
> converted the 991231 (YYMMDD) date fields to ICONV's. They had run from
1974
> through 1997 when I got on board with half of their dates that way and the
> rest as ICONV'd. But in 1999 it was justified to repair for obvious Y2K
> reasons.
>
> Mark Johnson.
>
> The Y2K situation didn't produce a whole lot of revenue for me. Day 10,000
> was more profitable although not record breaking either.
> ----- Original Message -----
> From: "Allen E. Elwood" <[EMAIL PROTECTED]>
> To: <[email protected]>
> Sent: Friday, September 02, 2005 1:34 PM
> Subject: RE: [U2] Date ICONV In English
>
>
> > I started to post this:
> > As far as I know the human readable is only used during output.  In
other
> > words, there is no conversion during sorting.  The system is already
> sorting
> > by the internal representation of the date.
> >
> > But now I realize that someone actually STORED the OCONV version of a
date
> > in a file??!!!  ROFLOL!!  Now that's funny.....
> >
> > -----Original Message-----
> > From: [EMAIL PROTECTED]
> > [mailto:[EMAIL PROTECTED] Behalf Of Mark Johnson
> > Sent: Friday, September 02, 2005 06:00
> > To: [email protected]
> > Subject: [U2] Date ICONV In English
> >
> >
> > To All:
> >
> > Is there any simple method short of an Itype or called routine to
convert
> > the
> > human date of 12/15/05 into its ICONV version to then sort by.
> >
> > I've run into another data file on a customer's system that has this in
a
> > specific place, albeit non-sortable. I could write a [] conversion to
put
> > the
> > year first, but I would like to know of a process code that may help.
> >
> > Thanks in advance.
> > Mark Johnson
> > -------
> > u2-users mailing list
> > [email protected]
> > To unsubscribe please visit http://listserver.u2ug.org/
> > -------
> > u2-users mailing list
> > [email protected]
> > To unsubscribe please visit http://listserver.u2ug.org/
> -------
> u2-users mailing list
> [email protected]
> To unsubscribe please visit http://listserver.u2ug.org/
> -------
> u2-users mailing list
> [email protected]
> To unsubscribe please visit http://listserver.u2ug.org/
-------
u2-users mailing list
[email protected]
To unsubscribe please visit http://listserver.u2ug.org/

Reply via email to