> -----Original Message-----
> From: [EMAIL PROTECTED]
> [mailto:[EMAIL PROTECTED] Behalf Of Timothy Snyder
> Sent: Friday, October 07, 2005 5:21 PM
> To: u2-users@listserver.u2ug.org
> Subject: RE: [U2] OPEN vs TRANS
> 
> 
> 
> Now, as to people who want to code one line instead of two (e.g.: the 
> topic of this thread), I say take a touch typing course so 
> you don't mind 
> a few extra keystrokes.  (I've always been amazed watching seasoned 
> professionals using only one finger on each hand to write 
> programs.)  I 
> would much rather inherit a program that does its own opens and reads 
> instead of doing translates.  Sooner or later somebody will 
> want to get a 
> second field from the record and you'll be faced with doing 
> two translates 
> or changing it to the way it should have been done in the 
> first place. 
> Plus, the OCONV with a translate isn't nearly as obvious to 
> the casual 
> observer of the code.  Of course, you could put in some 
> comments to make 
> it clear, 

Generally, when I use TRANS() in a program, I usually read the
whole record, so it doesn't matter if later down the road someone
needs another field.

Also, I don't use the OCONV() method with corelatives, I use the
VAR=RAISE(TRANS(filename,itemname,-1,'x')), which is pretty self
commenting, of course, that requires you to know what the TRANS()
keyword does.

For me, the only time converting from TRANS to OPEN down the road
is if someone needed to WRITE to the file, since you can't write
data using the TRANS(), and I didn't see any compatible write keyword
using the TRANS() format (aka, not having to open the file).

George



but those keystrokes could have been spent opening 
> the file at 
> the top of the program.
> 
> 
> Tim Snyder
-------
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/

Reply via email to