RE: [U2] OPEN vs TRANS

2005-10-12 Thread George Gallen
> -Original Message-
> From: [EMAIL PROTECTED]
> [mailto:[EMAIL PROTECTED] Behalf Of Timothy Snyder
> Sent: Tuesday, October 11, 2005 11:27 PM
> To: u2-users@listserver.u2ug.org
> Subject: RE: [U2] OPEN vs TRANS
> 
> 
> "George Gallen" <[EMAIL PROTECTED]> wrote on 10/11/2005 
> 02:01:52 PM:
> 
> > 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.
> 

As a replacment for OPEN/READ, no, TRANS is no benefit,but for a subroutine
or a program that only needs to read a table or whatever 1 time during
the execution of the program, then I don't see a problem with it. Again
it's a keyword, thus documentation is in the book. Now if it were embedded
in a block of code, you could comment the function of the block of code.
but to document the TRANS itself would be like commenting a Do/While loop
as ; * a do while loop (which to me makes a program longer and doesn't add
anything).


> I'm not trying to be difficult here - I'm just trying to see 
> the benefits 
> of this alternative to a straightforward and standard approach.
> 

nothing difficult...to each their own. Where I have it in use is quite clear
and quite maintainable.

> 
> Tim Snyder
> 

George
---
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/


RE: [U2] OPEN vs TRANS

2005-10-11 Thread Bruce Nichol

Goo'day,

At 23:26 11/10/05 -0400, you wrote:


"
I'm still trying to see how this is superior to a READ, which is entirely
self-documenting and efficient, and doesn't require you to know about how
TRANS behaves.  I suspect that most programmers would have to look at the
documentation or a help screen to know why you're doing a RAISE, and what
the -1 and the 'x' are all about.  Maybe I'm wrong about that.


It's all neatly explained in HELP BASIC TRANS and I'd hazard that anybody 
that wanted to go down *that* road (the "obfuscation path" I'd call it) 
in their code would soon get used to t'syntax




A line that starts out "VAR=" doesn't immediately say to me, "here's where
we're doing some I/O".  If I'm searching a program for I/O statements, I'm
not generally looking for something like this.  There's also the overhead
of doing the RAISE, which is only there to counteract the behavior of the
TRANS.  On small records this wouldn't be significant, but if you're
processing many large records, it could make a difference.

I'm not trying to be difficult here - I'm just trying to see the benefits
of this alternative to a straightforward and standard approach.


As far as I can see, the only "benefit" (???) *might* be that if the 
variable passed to a TRANS as the Item-ID for the file is a multi-valued 
list, the data returned is a list of fields for each item. This *might* 
have some benefit in timing. but for all I care, a READ is a READ is a 
READ (might even be a TRANS) regardless from whence it originates 
Hope I never get to having to  squeeze the nth degree of timing out of 
anything I write.


But, all that aside, I'm sure I can recall a UV support person (who shall 
remain nameless 'cos I can't remember who he/she is/was... Chris???. 
Trish??? - yep! that long ago) telling/advising that one shouldn't use 
TRANS for other than I-types... for some now obscure reason  but I 
think "slow" was mentioned.





Tim Snyder
Consulting I/T Specialist , U2 Professional Services
North American Lab Services
DB2 Information Management, IBM Software Group
717-545-6403
[EMAIL PROTECTED]
---
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/


--
No virus found in this incoming message.
Checked by AVG Anti-Virus.
Version: 7.0.344 / Virus Database: 267.11.14/129 - Release Date: 11/10/05




--
No virus found in this incoming message.
Checked by AVG Anti-Virus.
Version: 7.0.344 / Virus Database: 267.11.14/129 - Release Date: 11/10/05


Regards,

Bruce Nichol
Talon Computer Services
ALBURYNSW 2640
Australia

http://www.taloncs.com.au

Tel: +61 (0)411149636
Fax: +61 (0)260232119

If it ain't broke, fix it till it is! 



--
No virus found in this outgoing message.
Checked by AVG Anti-Virus.
Version: 7.0.344 / Virus Database: 267.11.14/129 - Release Date: 11/10/05
---
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/


RE: [U2] OPEN vs TRANS

2005-10-11 Thread phil walker
Just because you can doesn't mean you should.

UniVerse has many ways of doing things, some well and others not so
well. I like you cannot se any benefit in using a TRANS...

My 2 cents

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Timothy Snyder
Sent: Wednesday, 12 October 2005 4:46 p.m.
To: u2-users@listserver.u2ug.org
Subject: RE: [U2] OPEN vs TRANS

"George Gallen" <[EMAIL PROTECTED]> wrote on 10/11/2005 02:01:52 PM:

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

I'm still trying to see how this is superior to a READ, which is
entirely self-documenting and efficient, and doesn't require you to know
about how TRANS behaves.  I suspect that most programmers would have to
look at the documentation or a help screen to know why you're doing a
RAISE, and what the -1 and the 'x' are all about.  Maybe I'm wrong about
that.

A line that starts out "VAR=" doesn't immediately say to me, "here's
where we're doing some I/O".  If I'm searching a program for I/O
statements, I'm not generally looking for something like this.  There's
also the overhead of doing the RAISE, which is only there to counteract
the behavior of the TRANS.  On small records this wouldn't be
significant, but if you're processing many large records, it could make
a difference.

I'm not trying to be difficult here - I'm just trying to see the
benefits of this alternative to a straightforward and standard approach.


Tim Snyder
Consulting I/T Specialist , U2 Professional Services
North American Lab Services
DB2 Information Management, IBM Software Group
717-545-6403
[EMAIL PROTECTED]
---
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/
---
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/


RE: [U2] OPEN vs TRANS

2005-10-11 Thread Timothy Snyder
"George Gallen" <[EMAIL PROTECTED]> wrote on 10/11/2005 02:01:52 PM:

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

I'm still trying to see how this is superior to a READ, which is entirely 
self-documenting and efficient, and doesn't require you to know about how 
TRANS behaves.  I suspect that most programmers would have to look at the 
documentation or a help screen to know why you're doing a RAISE, and what 
the -1 and the 'x' are all about.  Maybe I'm wrong about that.

A line that starts out "VAR=" doesn't immediately say to me, "here's where 
we're doing some I/O".  If I'm searching a program for I/O statements, I'm 
not generally looking for something like this.  There's also the overhead 
of doing the RAISE, which is only there to counteract the behavior of the 
TRANS.  On small records this wouldn't be significant, but if you're 
processing many large records, it could make a difference.

I'm not trying to be difficult here - I'm just trying to see the benefits 
of this alternative to a straightforward and standard approach.


Tim Snyder
Consulting I/T Specialist , U2 Professional Services
North American Lab Services
DB2 Information Management, IBM Software Group
717-545-6403
[EMAIL PROTECTED]
---
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/


RE: [U2] OPEN vs TRANS

2005-10-11 Thread George Gallen
> -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/


RE: [U2] OPEN vs TRANS

2005-10-10 Thread BNeylon
The actual solution was for me to take the 2 minutes required to comment 
out the TRANS line, add code to open the file, readv the file, comment my 
code, compile and then catalog the program.  Someone who can really type 
would have finished the job in 30 seconds.  :-)
What really hurt was all the time was taken up trying to figure out why 
the flag being set by the TRANS was incorrect.  Now I know.  I have always 
been leery of using a Oconv TRANS in a databasic program.  I was under the 
impression the TRANS had to open the file every time the TRANS was 
executed, now I know better. :-)  Of course, if I had been correct I 
wouldn't have had the problem.  :-(
Learn something new every day.


Bruce M Neylon
Health Care Management Group 




"Keith W. Roberts" <[EMAIL PROTECTED]>
Sent by: [EMAIL PROTECTED]
10/10/2005 11:39 AM
Please respond to u2-users

 
To: , <[EMAIL PROTECTED]>
cc: 
        Subject:    RE: [U2] OPEN vs TRANS

I understood exactly what you were saying.  The "solution" was for the
case where the acct *wasn't* being exited and therefore @FILENAME,
@RECORD, etc. not flushed.  [Unless, of course, the "cache" you speak of
is something specific to TRANS() rather than the above, but I can't see
why that would be.]

-Keith

Original Message
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Glenn Herbert
Sent: Friday, October 07, 2005 2:17 PM
To: [EMAIL PROTECTED]; u2-users@listserver.u2ug.org;
[EMAIL PROTECTED]
Subject: RE: [U2] OPEN vs TRANS

>Why  do  you  believe doing this (Logto followed by LIST
> VOC...) would
>work  ( I don't think it will)?   I think you might have
>misunderstood what  I meant by "exiting the account" - that would
> be 
> using QUIT.   I
>guess I should have been more clear by saying "quitting universe".
> 
> __
> 
>From: [EMAIL PROTECTED]
>[mailto:[EMAIL PROTECTED]  On  Behalf
> Of  "Keith W.
>    Roberts" <[EMAIL PROTECTED]>
>Sent: Friday, October 07, 2005 1:27 PM
>To: ; <[EMAIL PROTECTED]>
>Subject: RE: [U2] OPEN vs TRANS
> 
>Possible workaround?
>Whenever you LOGTO, do a LIST VOC SAMPLE 1 (HUSHed) to
> change the file
>and record pointers.
>-Keith
>
>Original Message
>From: [EMAIL PROTECTED]
>    [mailto:[EMAIL PROTECTED] On Behalf Of
> Glenn Herbert
>Sent: Friday, October 07, 2005 9:35 AM
>To: [EMAIL PROTECTED]; u2-users@listserver.u2ug.org
>Subject: RE: [U2] OPEN vs TRANS
>> You are 100% correct and this is a known issue (to me>
>anyways). The > cache is only flushed when exiting the account or
>when you> return back > to TCL. Unfortunately, there is no
>direct way to call> the internal > transclear() function.
> 
> __________________
>> > From: [EMAIL PROTECTED]
>> [mailto:[EMAIL PROTECTED] On> Behalf Of
>> [EMAIL PROTECTED]
>> Sent: Friday, October 07, 2005 11:22 AM
>> To: u2-users@listserver.u2ug.org
>> Subject: RE: [U2] OPEN vs TRANS
>>
>> Our system has many accounts with, basically, the same
> file names,
>> layouts, etc. We found a problem with using the translate>
>rather than > open/read in programs.
>> If a program logs from account to account and accesses> info
>with a > trans,
>> the trans doesn't always open and read the file in the> new
>account's > file,
>> rather the trans retrieves the info from an earlier account.
>> Am I right is supposing this phenomena is due to the file>
>and record > having the same ID and logging to another account 
>> doesn't flush the > cache?
>> Thanks,
>> Bruce
---
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/
---
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/


RE: [U2] OPEN vs TRANS

2005-10-10 Thread Keith W. Roberts
I understood exactly what you were saying.  The "solution" was for the
case where the acct *wasn't* being exited and therefore @FILENAME,
@RECORD, etc. not flushed.  [Unless, of course, the "cache" you speak of
is something specific to TRANS() rather than the above, but I can't see
why that would be.]

-Keith

Original Message
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Glenn Herbert
Sent: Friday, October 07, 2005 2:17 PM
To: [EMAIL PROTECTED]; u2-users@listserver.u2ug.org;
[EMAIL PROTECTED]
Subject: RE: [U2] OPEN vs TRANS

>Why  do  you  believe doing this (Logto followed by LIST
> VOC...) would
>work  ( I don't think it will)?   I think you might have
>misunderstood what  I meant by "exiting the account" - that would
> be 
> using QUIT.   I
>guess I should have been more clear by saying "quitting universe".
> 
> __
> 
>From: [EMAIL PROTECTED]
>[mailto:[EMAIL PROTECTED]  On  Behalf
> Of  "Keith W.
>Roberts" <[EMAIL PROTECTED]>
>Sent: Friday, October 07, 2005 1:27 PM
>To: ; <[EMAIL PROTECTED]>
>Subject: RE: [U2] OPEN vs TRANS
> 
>Possible workaround?
>Whenever you LOGTO, do a LIST VOC SAMPLE 1 (HUSHed) to
> change the file
>and record pointers.
>-Keith
>
>Original Message
>From: [EMAIL PROTECTED]
>[mailto:[EMAIL PROTECTED] On Behalf Of
> Glenn Herbert
>Sent: Friday, October 07, 2005 9:35 AM
>To: [EMAIL PROTECTED]; u2-users@listserver.u2ug.org
>Subject: RE: [U2] OPEN vs TRANS
>> You are 100% correct and this is a known issue (to me>
>anyways). The > cache is only flushed when exiting the account or
>when you> return back > to TCL. Unfortunately, there is no
>direct way to call> the internal > transclear() function.
> 
> __
>    > > From: [EMAIL PROTECTED]
>> [mailto:[EMAIL PROTECTED] On> Behalf Of
>> [EMAIL PROTECTED]
>> Sent: Friday, October 07, 2005 11:22 AM
>> To: u2-users@listserver.u2ug.org
>> Subject: RE: [U2] OPEN vs TRANS
>>
>> Our system has many accounts with, basically, the same
> file names,
>> layouts, etc. We found a problem with using the translate>
>rather than > open/read in programs.
>> If a program logs from account to account and accesses> info
>with a > trans,
>> the trans doesn't always open and read the file in the> new
>account's > file,
>> rather the trans retrieves the info from an earlier account.
>> Am I right is supposing this phenomena is due to the file>
>and record > having the same ID and logging to another account   
>> doesn't flush the > cache?
>> Thanks,
>> Bruce
---
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/


RE: [U2] OPEN vs TRANS

2005-10-10 Thread Keith W. Roberts
That was the idea, but I wasn't discussing implememntation, only a
technique that might solve the problem.

-Keith

Original Message
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of
Allen E. Elwood
Sent: Friday, October 07, 2005 1:20 PM
To: u2-users@listserver.u2ug.org
Subject: RE: [U2] OPEN vs TRANS

> Hey Keith,
> 
> That's a really great idea, but why not just add it to the
> LOGIN paragraph?
> (it's in the VOC on Unidata systems) Then you won't have to
> stub the LOGTO
> command!
> 
> Allen
> www.tortillafc.com
> 
> -Original Message-
> From: [EMAIL PROTECTED]
> [mailto:[EMAIL PROTECTED] Behalf Of Keith
> W. Roberts
> Sent: Friday, October 07, 2005 10:27
> To: u2-users@listserver.u2ug.org; [EMAIL PROTECTED]
> Subject: RE: [U2] OPEN vs TRANS
> 
> 
> Possible workaround?
> 
> Whenever you LOGTO, do a LIST VOC SAMPLE 1 (HUSHed) to change the
> file and record pointers. 
> 
> -Keith
> 
> Original Message
> From: [EMAIL PROTECTED]
> [mailto:[EMAIL PROTECTED] On Behalf Of Glenn Herbert
> Sent: Friday, October 07, 2005 9:35 AM
> To: [EMAIL PROTECTED]; u2-users@listserver.u2ug.org
> Subject: RE: [U2] OPEN vs TRANS
> 
>>You  are  100% correct and this is a known issue (to me anyways).
>>The cache is only flushed when exiting the account or when you
>>return back to  TCL.   Unfortunately,  there is no direct way to
>>call the internal transclear() function.
>> 
>> 
>> 
> __
>> 
>>From: [EMAIL PROTECTED]
>>    [mailto:[EMAIL PROTECTED]  On
>> Behalf Of
>>[EMAIL PROTECTED]
>>Sent: Friday, October 07, 2005 11:22 AM
>>To: u2-users@listserver.u2ug.org
>>Subject: RE: [U2] OPEN vs TRANS
>> 
>>Our system has many accounts with, basically, the same file names,
>>layouts, etc. We found a problem with using the translate rather
>>than open/read in programs.
>>If  a  program  logs  from account to account and accesses info
>>with a trans,
>>the  trans  doesn't always open and read the file in the new
>>account's file,
>>rather the trans retrieves the info from an earlier account.
>>Am I right is supposing this phenomena is due to the file and
>>record having  the  same  ID and logging to another account
>>doesn't flush the cache?
>>Thanks,
>>Bruce
---
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/


RE: [U2] OPEN vs TRANS + Vector

2005-10-10 Thread Stuart . Boydell
   Wow, thanks! and caveat heeded.
   Vectorally (and RTFM) challenged,
   Stuart

   -Original Message-
   From:  "Stevenson, Charles"

 Vectoring (is 'vector' a verb?) is built into TRANS already.
 No need to abandon in favour of OCONVS T-correlative.
 You can specify a dynamic array of IDs for the target file to read.
 > I have used the Translate code with OCONVS() function when it
 > is stylistically in keeping with the use of vector functions
 > around it and only because there isn't a vector version of
 >  TRANS(),  but  personally  I  wouldn't  use  it  outside of that
 situation.
 >
 > custProductIDs = splice(reuse(custId),'*',productIds)
 instead of / as well as this:
 > prices = oconvs(custProductIDs,'TCUST.PRODUCT;X;;99')
 this works fine (even better I think):
 prices = TRANS( 'CUST.PRODUCT', custProductIDs, 99, 'X' )
 But a caution:
 If CUST.PRODUCT <99> is multivalued &/or sub-valued:
 *  T-correlative  converts  all  delimiters  to  spaces when OCONVS
 returns.
 (consistent with PICK.)
 * TRANS will lower the returned delimiters.
 (almost consistent with PI.)
 - if called from Retrieve, the delimiters are lowered enough to
 keep the association with the dict equivalent of custProductIDs
 which might be multi-SUB-valued or even have TMs or lower.
 - if called from Basic, not that smart, just lowered once,
 so you might lose the association with custProductIDs.
 The above for UV. Mileage for UD may vary.
 cds
 ---
 u2-users mailing list
 u2-users@listserver.u2ug.org
 To unsubscribe please visit http://listserver.u2ug.org/

   **

   This email message and any files transmitted with it are confidential

   and intended solely for the use of addressed recipient(s). If you have

   received  this  email  in  error please notify the Spotless IS Support
   Centre (+61 3 9269 7555) immediately, who will advise further action.

   This footnote also confirms that this email message has been scanned

   for the presence of computer related viruses.

   **
---
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/


RE: [U2] OPEN vs TRANS

2005-10-09 Thread Stevenson, Charles
Vectoring (is 'vector' a verb?) is built into TRANS already.  
No need to abandon in favour of OCONVS T-correlative.
You can specify a dynamic array of IDs for the target file to read.

> I have used the Translate code with OCONVS() function when it 
> is stylistically in keeping with the use of vector functions 
> around it and only because there isn't a vector version of 
> TRANS(), but personally I wouldn't use it outside of that situation.
> 
>   custProductIDs = splice(reuse(custId),'*',productIds)

instead of / as well as this:

>   prices = oconvs(custProductIDs,'TCUST.PRODUCT;X;;99')

this works fine (even better I think):

prices = TRANS( 'CUST.PRODUCT', custProductIDs, 99, 'X' )


But a caution:

If CUST.PRODUCT <99> is multivalued &/or sub-valued:
 
 * T-correlative converts all delimiters to spaces when OCONVS returns.
 (consistent with PICK.)

 * TRANS will lower the returned delimiters. 
(almost consistent with PI.)
- if called from Retrieve, the delimiters are lowered enough to
keep the association with the dict equivalent of custProductIDs
which might be multi-SUB-valued or even have TMs or lower.
- if called from Basic, not that smart, just lowered once,
so you might lose the association with custProductIDs.


The above for UV. Mileage for UD may vary.

cds
---
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/


RE: [U2] OPEN vs TRANS

2005-10-09 Thread Stuart . Boydell
> I've actually run into a program with 10 READV's, some processing then 10


> WRITEV's for the obvious same record in the same file.

>

> Is the OCONV(translate) function any more or less effecient in BASIC than
in

> English (sic). I use them for simple validation or to retrieve one field

> with no side effects. If I need another field, I use OPEN and READ.



I have used the Translate code with OCONVS() function when it is
stylistically in keeping with the use of vector functions around it and
only because there isn't a vector version of TRANS(), but personally I
wouldn't use it outside of that situation.



  custProductIDs = splice(reuse(custId),'*',productIds)

  prices = oconvs(custProductIDs,'TCUST.PRODUCT','X';;99)



Stuart



**
This email message and any files transmitted with it are confidential
and intended solely for the use of addressed recipient(s). If you have 
received this email in error please notify the Spotless IS Support Centre (+61 
3 9269 7555) immediately, who will advise further action.

This footnote also confirms that this email message has been scanned
for the presence of computer related viruses.

**
---
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/


Re: [U2] OPEN vs TRANS

2005-10-09 Thread Don Kibbey
Yep, I've recently went on several site visits to other Law Firms
running two different billing packages on SQL Server.  All 6 had
converted from a UniVerse system running on HP-UX.  All 6 mentioned
the letdown of running a large query against their spanking new "uber"
machines only to find they had a significant performance lag when
compared to the "ancient" HP-UX machines running a very well designed
UniVerse application.

In the Oracle, SQL server, arena, performance problems are solved with
the check book and more/faster hardware.

On 10/7/05, Dan Fitzgerald <[EMAIL PROTECTED]> wrote:
> Amen. Allow me to add that often the decision to replace an MV database with
> an RDBMS hinges on, "what do you mean I need 5 times as much
> hardware/horsepower to run Oracle?".
>
>
>
> "Our greatest duty in this life is to help others. And please, if you can't
> help them, could you at least not hurt them?" - H.H. the Dalai Lama
> "When buying & selling are controlled by legislation, the first thing to be
> bought & sold are the legislators" - P.J. O'Rourke
> Dan Fitzgerald
>
>
>
>
>
> >From: Timothy Snyder <[EMAIL PROTECTED]>
> >Reply-To: u2-users@listserver.u2ug.org
> >To: u2-users@listserver.u2ug.org
> >Subject: RE: [U2] OPEN vs TRANS
> >Date: Fri, 7 Oct 2005 17:21:28 -0400
> >
> >"Allen E. Elwood" <[EMAIL PROTECTED]> wrote on 10/07/2005 12:53:47 PM:
> >
> > > The way I look at it, when I started programming 30 years ago systems
> >were
> > > millions of times slower, and in another 30 years they'll be so stinking
> > > fast that coding for speed will go the way of the Suchomimus and the
> > > Iguanodon!
> >
> >As long as programmers think that way, their employers will continue to
> >pay people like me big bucks to come in and make the code more efficient.
> >;-)  Sometimes more powerful systems can make bottlenecks more prominent.
> >Today's systems are expected to process more data in a shorter time, and
> >to provide more functionality than in days of yore, so even minor
> >inefficiencies are encountered over and over again.  IMHO, there will
> >always be room for efficient coding techniques.  Some folks claim you have
> >to sacrifice maintainability and readability for the sake of efficiency -
> >I've rarely found that to be true.  As long as you care about and consider
> >both performance and maintainability as you develop code, it all just
> >falls together.
> >
> >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, but those keystrokes could have been spent opening the file at
> >the top of the program.
> >
> >
> >Tim Snyder
> >Consulting I/T Specialist , U2 Professional Services
> >North American Lab Services
> >DB2 Information Management, IBM Software Group
> >717-545-6403
> >[EMAIL PROTECTED]
> >---
> >u2-users mailing list
> >u2-users@listserver.u2ug.org
> >To unsubscribe please visit http://listserver.u2ug.org/
> ---
> u2-users mailing list
> u2-users@listserver.u2ug.org
> To unsubscribe please visit http://listserver.u2ug.org/
---
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/


RE: [U2] OPEN vs TRANS

2005-10-08 Thread Allen E. Elwood
In situations where there are multiple reads I usually just pass the whole
@RECORD.

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] Behalf Of Mark Johnson
Sent: Friday, October 07, 2005 21:52
To: u2-users@listserver.u2ug.org
Subject: Re: [U2] OPEN vs TRANS


I've actually run into a program with 10 READV's, some processing then 10
WRITEV's for the obvious same record in the same file.

Is the OCONV(translate) function any more or less effecient in BASIC than in
English (sic). I use them for simple validation or to retrieve one field
with no side effects. If I need another field, I use OPEN and READ.

Thanks
Mark Johnson
- Original Message -
From: "Timothy Snyder" <[EMAIL PROTECTED]>
To: 
Sent: Friday, October 07, 2005 5:21 PM
Subject: RE: [U2] OPEN vs TRANS


> "Allen E. Elwood" <[EMAIL PROTECTED]> wrote on 10/07/2005 12:53:47 PM:
>
> > The way I look at it, when I started programming 30 years ago systems
> were
> > millions of times slower, and in another 30 years they'll be so stinking
> > fast that coding for speed will go the way of the Suchomimus and the
> > Iguanodon!
>
> As long as programmers think that way, their employers will continue to
> pay people like me big bucks to come in and make the code more efficient.
> ;-)  Sometimes more powerful systems can make bottlenecks more prominent.
> Today's systems are expected to process more data in a shorter time, and
> to provide more functionality than in days of yore, so even minor
> inefficiencies are encountered over and over again.  IMHO, there will
> always be room for efficient coding techniques.  Some folks claim you have
> to sacrifice maintainability and readability for the sake of efficiency -
> I've rarely found that to be true.  As long as you care about and consider
> both performance and maintainability as you develop code, it all just
> falls together.
>
> 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, but those keystrokes could have been spent opening the file at
> the top of the program.
>
>
> Tim Snyder
> Consulting I/T Specialist , U2 Professional Services
> North American Lab Services
> DB2 Information Management, IBM Software Group
> 717-545-6403
> [EMAIL PROTECTED]
> ---
> u2-users mailing list
> u2-users@listserver.u2ug.org
> To unsubscribe please visit http://listserver.u2ug.org/
---
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/
---
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/


Re: [U2] OPEN vs TRANS

2005-10-07 Thread Mark Johnson
I've actually run into a program with 10 READV's, some processing then 10
WRITEV's for the obvious same record in the same file.

Is the OCONV(translate) function any more or less effecient in BASIC than in
English (sic). I use them for simple validation or to retrieve one field
with no side effects. If I need another field, I use OPEN and READ.

Thanks
Mark Johnson
- Original Message -
From: "Timothy Snyder" <[EMAIL PROTECTED]>
To: 
Sent: Friday, October 07, 2005 5:21 PM
Subject: RE: [U2] OPEN vs TRANS


> "Allen E. Elwood" <[EMAIL PROTECTED]> wrote on 10/07/2005 12:53:47 PM:
>
> > The way I look at it, when I started programming 30 years ago systems
> were
> > millions of times slower, and in another 30 years they'll be so stinking
> > fast that coding for speed will go the way of the Suchomimus and the
> > Iguanodon!
>
> As long as programmers think that way, their employers will continue to
> pay people like me big bucks to come in and make the code more efficient.
> ;-)  Sometimes more powerful systems can make bottlenecks more prominent.
> Today's systems are expected to process more data in a shorter time, and
> to provide more functionality than in days of yore, so even minor
> inefficiencies are encountered over and over again.  IMHO, there will
> always be room for efficient coding techniques.  Some folks claim you have
> to sacrifice maintainability and readability for the sake of efficiency -
> I've rarely found that to be true.  As long as you care about and consider
> both performance and maintainability as you develop code, it all just
> falls together.
>
> 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, but those keystrokes could have been spent opening the file at
> the top of the program.
>
>
> Tim Snyder
> Consulting I/T Specialist , U2 Professional Services
> North American Lab Services
> DB2 Information Management, IBM Software Group
> 717-545-6403
> [EMAIL PROTECTED]
> ---
> u2-users mailing list
> u2-users@listserver.u2ug.org
> To unsubscribe please visit http://listserver.u2ug.org/
---
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/


Re: [U2] OPEN vs TRANS

2005-10-07 Thread Mark Johnson
I agree. That's what we consultants are for. To help our clients make
intelligent decisions.
- Original Message -
From: "Larry Hiscock" <[EMAIL PROTECTED]>
To: 
Sent: Friday, October 07, 2005 7:12 PM
Subject: RE: [U2] OPEN vs TRANS


> Sometimes you have to educate your clients as to what they "want".
>
> Larry Hiscock
> Western Computer Services
>
>
> -Original Message-
> From: [EMAIL PROTECTED]
> [mailto:[EMAIL PROTECTED] On Behalf Of Bruce Nichol
> Sent: Friday, October 07, 2005 3:36 PM
> To: u2-users@listserver.u2ug.org
> Subject: RE: [U2] OPEN vs TRANS
>
> Goo'day,
>
> At 14:50 07/10/05 -0700, you wrote:
>
>
> >Being independent, you have to listen to what the *client* wants.  Do
> >they need me to spend an additional 40 hours at $110 an hour to make
> >something run faster?  Most clients say N!!
>
> My customers say it louder than that..
>
>
> >Allen
> >www.tortillafc.com
> >
> >
> >
> >--
> >No virus found in this incoming message.
> >Checked by AVG Anti-Virus.
> >Version: 7.0.344 / Virus Database: 267.11.13/124 - Release Date:
> >07/10/05
>
> Regards,
>
> Bruce Nichol
> Talon Computer Services
> ALBURYNSW 2640
> Australia
>
> http://www.taloncs.com.au
>
> Tel: +61 (0)411149636
> Fax: +61 (0)260232119
>
> If it ain't broke, fix it till it is!
>
>
> --
> No virus found in this outgoing message.
> Checked by AVG Anti-Virus.
> Version: 7.0.344 / Virus Database: 267.11.13/124 - Release Date: 07/10/05
> ---
> u2-users mailing list
> u2-users@listserver.u2ug.org
> To unsubscribe please visit http://listserver.u2ug.org/
> ---
> u2-users mailing list
> u2-users@listserver.u2ug.org
> To unsubscribe please visit http://listserver.u2ug.org/
---
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/


RE: [U2] OPEN vs TRANS

2005-10-07 Thread Larry Hiscock
Sometimes you have to educate your clients as to what they "want".

Larry Hiscock
Western Computer Services
 

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Bruce Nichol
Sent: Friday, October 07, 2005 3:36 PM
To: u2-users@listserver.u2ug.org
Subject: RE: [U2] OPEN vs TRANS

Goo'day,

At 14:50 07/10/05 -0700, you wrote:


>Being independent, you have to listen to what the *client* wants.  Do 
>they need me to spend an additional 40 hours at $110 an hour to make 
>something run faster?  Most clients say N!!

My customers say it louder than that..


>Allen
>www.tortillafc.com
>
>
>
>--
>No virus found in this incoming message.
>Checked by AVG Anti-Virus.
>Version: 7.0.344 / Virus Database: 267.11.13/124 - Release Date: 
>07/10/05

Regards,

Bruce Nichol
Talon Computer Services
ALBURYNSW 2640
Australia

http://www.taloncs.com.au

Tel: +61 (0)411149636
Fax: +61 (0)260232119

If it ain't broke, fix it till it is! 


--
No virus found in this outgoing message.
Checked by AVG Anti-Virus.
Version: 7.0.344 / Virus Database: 267.11.13/124 - Release Date: 07/10/05
---
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/
---
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/


RE: [U2] OPEN vs TRANS

2005-10-07 Thread Bruce Nichol

Goo'day,

At 14:50 07/10/05 -0700, you wrote:



Being independent, you have to listen to what the *client* wants.  Do they
need me to spend an additional 40 hours at $110 an hour to make something
run faster?  Most clients say N!!


My customers say it louder than that..



Allen
www.tortillafc.com



--
No virus found in this incoming message.
Checked by AVG Anti-Virus.
Version: 7.0.344 / Virus Database: 267.11.13/124 - Release Date: 07/10/05


Regards,

Bruce Nichol
Talon Computer Services
ALBURYNSW 2640
Australia

http://www.taloncs.com.au

Tel: +61 (0)411149636
Fax: +61 (0)260232119

If it ain't broke, fix it till it is! 



--
No virus found in this outgoing message.
Checked by AVG Anti-Virus.
Version: 7.0.344 / Virus Database: 267.11.13/124 - Release Date: 07/10/05
---
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/


RE: [U2] OPEN vs TRANS

2005-10-07 Thread Dan Fitzgerald
Amen. Allow me to add that often the decision to replace an MV database with 
an RDBMS hinges on, "what do you mean I need 5 times as much 
hardware/horsepower to run Oracle?".




"Our greatest duty in this life is to help others. And please, if you can't 
help them, could you at least not hurt them?" - H.H. the Dalai Lama
"When buying & selling are controlled by legislation, the first thing to be 
bought & sold are the legislators" - P.J. O'Rourke

Dan Fitzgerald






From: Timothy Snyder <[EMAIL PROTECTED]>
Reply-To: u2-users@listserver.u2ug.org
To: u2-users@listserver.u2ug.org
Subject: RE: [U2] OPEN vs TRANS
Date: Fri, 7 Oct 2005 17:21:28 -0400

"Allen E. Elwood" <[EMAIL PROTECTED]> wrote on 10/07/2005 12:53:47 PM:

> The way I look at it, when I started programming 30 years ago systems
were
> millions of times slower, and in another 30 years they'll be so stinking
> fast that coding for speed will go the way of the Suchomimus and the
> Iguanodon!

As long as programmers think that way, their employers will continue to
pay people like me big bucks to come in and make the code more efficient.
;-)  Sometimes more powerful systems can make bottlenecks more prominent.
Today's systems are expected to process more data in a shorter time, and
to provide more functionality than in days of yore, so even minor
inefficiencies are encountered over and over again.  IMHO, there will
always be room for efficient coding techniques.  Some folks claim you have
to sacrifice maintainability and readability for the sake of efficiency -
I've rarely found that to be true.  As long as you care about and consider
both performance and maintainability as you develop code, it all just
falls together.

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, but those keystrokes could have been spent opening the file at
the top of the program.


Tim Snyder
Consulting I/T Specialist , U2 Professional Services
North American Lab Services
DB2 Information Management, IBM Software Group
717-545-6403
[EMAIL PROTECTED]
---
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/

---
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/


RE: [U2] OPEN vs TRANS

2005-10-07 Thread Allen E. Elwood
>As long as programmers think that way, their employers will continue to
>pay people like me big bucks to come in and make the code more efficient.

Like I said, at 175 an hour the ***client*** preferred the quickest coding
method.  So sometimes you get the big bucks to save time in **programming**.
(This was when my boss collected the money - I charge less now that I'm
independent)

And have you tested both methods to even see which is faster?

I have and to tell the truth I could not see any difference in speed between
opening the file and putting it in common and readv'ing the attributes and
just using the TRANS'd code.  I didn't use any fancy methods, just listed
the file and saw that it apparently didn't make any visual difference in
speed.

Since Uniquery *is* opening the file and keeping it open internally, what
*exactly* is the difference between letting the system do the work for you
or doing the same thing in a program?

Other questions:

How often will this dict item be used in a report.  Once a month?  Ten times
a day?  These make the decision to code more efficiently an issue, or not.

And after 31 years of programming, I only use one hand to type if the other
has a big honkin chicken taco in it.  Rest of the time I type at about
120wpm.  Speaking of which, I forgot to finish my second tacoyum.

Being independent, you have to listen to what the *client* wants.  Do they
need me to spend an additional 40 hours at $110 an hour to make something
run faster?  Most clients say N!!

Allen
www.tortillafc.com

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] Behalf Of Timothy Snyder
Sent: Friday, October 07, 2005 14:21
To: u2-users@listserver.u2ug.org
Subject: RE: [U2] OPEN vs TRANS


"Allen E. Elwood" <[EMAIL PROTECTED]> wrote on 10/07/2005 12:53:47 PM:

> The way I look at it, when I started programming 30 years ago systems
were
> millions of times slower, and in another 30 years they'll be so stinking
> fast that coding for speed will go the way of the Suchomimus and the
> Iguanodon!

As long as programmers think that way, their employers will continue to
pay people like me big bucks to come in and make the code more efficient.
;-)  Sometimes more powerful systems can make bottlenecks more prominent.
Today's systems are expected to process more data in a shorter time, and
to provide more functionality than in days of yore, so even minor
inefficiencies are encountered over and over again.  IMHO, there will
always be room for efficient coding techniques.  Some folks claim you have
to sacrifice maintainability and readability for the sake of efficiency -
I've rarely found that to be true.  As long as you care about and consider
both performance and maintainability as you develop code, it all just
falls together.

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, but those keystrokes could have been spent opening the file at
the top of the program.


Tim Snyder
Consulting I/T Specialist , U2 Professional Services
North American Lab Services
DB2 Information Management, IBM Software Group
717-545-6403
[EMAIL PROTECTED]
---
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/
---
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/


RE: [U2] OPEN vs TRANS

2005-10-07 Thread Timothy Snyder
"Allen E. Elwood" <[EMAIL PROTECTED]> wrote on 10/07/2005 12:53:47 PM:

> The way I look at it, when I started programming 30 years ago systems 
were
> millions of times slower, and in another 30 years they'll be so stinking
> fast that coding for speed will go the way of the Suchomimus and the
> Iguanodon!

As long as programmers think that way, their employers will continue to 
pay people like me big bucks to come in and make the code more efficient. 
;-)  Sometimes more powerful systems can make bottlenecks more prominent. 
Today's systems are expected to process more data in a shorter time, and 
to provide more functionality than in days of yore, so even minor 
inefficiencies are encountered over and over again.  IMHO, there will 
always be room for efficient coding techniques.  Some folks claim you have 
to sacrifice maintainability and readability for the sake of efficiency - 
I've rarely found that to be true.  As long as you care about and consider 
both performance and maintainability as you develop code, it all just 
falls together.

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, but those keystrokes could have been spent opening the file at 
the top of the program.


Tim Snyder
Consulting I/T Specialist , U2 Professional Services
North American Lab Services
DB2 Information Management, IBM Software Group
717-545-6403
[EMAIL PROTECTED]
---
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/


RE: [U2] OPEN vs TRANS

2005-10-07 Thread Glenn Herbert
   Why  do  you  believe doing this (Logto followed by LIST VOC...) would
   work  ( I don't think it will)?   I think you might have misunderstood
   what  I meant by "exiting the account" - that would be using QUIT.   I
   guess I should have been more clear by saying "quitting universe".

   __

   From: [EMAIL PROTECTED]
   [mailto:[EMAIL PROTECTED]  On  Behalf  Of  "Keith W.
   Roberts" <[EMAIL PROTECTED]>
   Sent: Friday, October 07, 2005 1:27 PM
   To: ; <[EMAIL PROTECTED]>
   Subject: RE: [U2] OPEN vs TRANS

   Possible workaround?
   Whenever you LOGTO, do a LIST VOC SAMPLE 1 (HUSHed) to change the file
   and record pointers.
   -Keith
   Original Message
   From: [EMAIL PROTECTED]
   [mailto:[EMAIL PROTECTED] On Behalf Of Glenn Herbert
   Sent: Friday, October 07, 2005 9:35 AM
   To: [EMAIL PROTECTED]; u2-users@listserver.u2ug.org
   Subject: RE: [U2] OPEN vs TRANS
   > You are 100% correct and this is a known issue (to me
   > anyways). The
   > cache is only flushed when exiting the account or when you
   > return back
   > to TCL. Unfortunately, there is no direct way to call
   > the internal
   > transclear() function.
   >
   >
   >
   __
   >
   > From: [EMAIL PROTECTED]
   > [mailto:[EMAIL PROTECTED] On
   > Behalf Of
   > [EMAIL PROTECTED]
   > Sent: Friday, October 07, 2005 11:22 AM
   > To: u2-users@listserver.u2ug.org
   > Subject: RE: [U2] OPEN vs TRANS
   >
   > Our system has many accounts with, basically, the same file names,
   > layouts, etc. We found a problem with using the translate
   > rather than
   > open/read in programs.
   > If a program logs from account to account and accesses
   > info with a
   > trans,
   > the trans doesn't always open and read the file in the
   > new account's
   > file,
   > rather the trans retrieves the info from an earlier account.
   > Am I right is supposing this phenomena is due to the file
   > and record
   > having the same ID and logging to another account
   > doesn't flush the
   > cache?
   > Thanks,
   > Bruce
   ---
   u2-users mailing list
   u2-users@listserver.u2ug.org
   To unsubscribe please visit http://listserver.u2ug.org/
---
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/


RE: [U2] OPEN vs TRANS

2005-10-07 Thread Allen E. Elwood
Hey Keith,

That's a really great idea, but why not just add it to the LOGIN paragraph?
(it's in the VOC on Unidata systems) Then you won't have to stub the LOGTO
command!

Allen
www.tortillafc.com

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] Behalf Of Keith W. Roberts
Sent: Friday, October 07, 2005 10:27
To: u2-users@listserver.u2ug.org; [EMAIL PROTECTED]
Subject: RE: [U2] OPEN vs TRANS


Possible workaround?

Whenever you LOGTO, do a LIST VOC SAMPLE 1 (HUSHed) to change the file
and record pointers.

-Keith

Original Message
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Glenn Herbert
Sent: Friday, October 07, 2005 9:35 AM
To: [EMAIL PROTECTED]; u2-users@listserver.u2ug.org
Subject: RE: [U2] OPEN vs TRANS

>You  are  100% correct and this is a known issue (to me
> anyways).  The
>cache is only flushed when exiting the account or when you
> return back
>to  TCL.   Unfortunately,  there is no direct way to call
> the internal
>transclear() function.
>
>
> __
>
>From: [EMAIL PROTECTED]
>[mailto:[EMAIL PROTECTED]  On
> Behalf Of
>[EMAIL PROTECTED]
>Sent: Friday, October 07, 2005 11:22 AM
>    To: u2-users@listserver.u2ug.org
>Subject: RE: [U2] OPEN vs TRANS
>
>Our system has many accounts with, basically, the same file names,
>layouts, etc. We found a problem with using the translate
> rather than
>open/read in programs.
>If  a  program  logs  from account to account and accesses
> info with a
>trans,
>the  trans  doesn't always open and read the file in the
> new account's
>file,
>rather the trans retrieves the info from an earlier account.
>Am I right is supposing this phenomena is due to the file
> and record
>having  the  same  ID and logging to another account
> doesn't flush the
>cache?
>Thanks,
>Bruce
---
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/
---
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/


RE: [U2] OPEN vs TRANS

2005-10-07 Thread George Gallen
hmm. The fact that the files are cached makes it nicer.

I didn't want to use it inside a loop (TRANS() that is), and waste
a lot of time with repeated OPEN/READs, in that case I'd have done
an OPEN, then used READS.

But if the OPEN is cached, great, it's just like doing the OPEN once.

Since this application does not need to write, nor set locks, the
TRANS may be a nice option.

George
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] Behalf Of Allen E. Elwood
Sent: Friday, October 07, 2005 12:54 PM
To: u2-users@listserver.u2ug.org
Subject: RE: [U2] OPEN vs TRANS


Hey George,

I've always established dict names using TRANS in the base file, and then
created my SUBR type DICT and passed them that way.  It just makes it *so*
much easier to code, and have really never noticed any difference between
the TRANS method or using OPEN and READS.

Plus most of the times I was doing this my boss was charging the client 175
an hour and speed of programming was considered MUCH more important than
speed of execution.

The way I look at it, when I started programming 30 years ago systems were
millions of times slower, and in another 30 years they'll be so stinking
fast that coding for speed will go the way of the Suchomimus and the
Iguanodon!

Like...systems will be accessing data at quad-terabytes per nanosecond over
wireless photonic motherboards the size of a dime.you know?

http://www.dinosauria.com/dml/dmlf.htm

Allen
---
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/


RE: [U2] OPEN vs TRANS

2005-10-07 Thread Keith W. Roberts
Possible workaround?

Whenever you LOGTO, do a LIST VOC SAMPLE 1 (HUSHed) to change the file
and record pointers.

-Keith

Original Message
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Glenn Herbert
Sent: Friday, October 07, 2005 9:35 AM
To: [EMAIL PROTECTED]; u2-users@listserver.u2ug.org
Subject: RE: [U2] OPEN vs TRANS

>You  are  100% correct and this is a known issue (to me
> anyways).  The
>cache is only flushed when exiting the account or when you
> return back
>to  TCL.   Unfortunately,  there is no direct way to call
> the internal
>transclear() function.
> 
> 
> __
> 
>From: [EMAIL PROTECTED]
>[mailto:[EMAIL PROTECTED]  On
> Behalf Of
>[EMAIL PROTECTED]
>Sent: Friday, October 07, 2005 11:22 AM
>    To: u2-users@listserver.u2ug.org
>Subject: RE: [U2] OPEN vs TRANS
> 
>Our system has many accounts with, basically, the same file names,
>layouts, etc. We found a problem with using the translate
> rather than
>open/read in programs.
>If  a  program  logs  from account to account and accesses
> info with a
>trans,
>the  trans  doesn't always open and read the file in the
> new account's
>file,
>rather the trans retrieves the info from an earlier account.
>Am I right is supposing this phenomena is due to the file
> and record
>having  the  same  ID and logging to another account
> doesn't flush the
>cache?
>Thanks,
>Bruce
---
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/


RE: [U2] OPEN vs TRANS

2005-10-07 Thread Allen E. Elwood
Hey George,

I've always established dict names using TRANS in the base file, and then
created my SUBR type DICT and passed them that way.  It just makes it *so*
much easier to code, and have really never noticed any difference between
the TRANS method or using OPEN and READS.

Plus most of the times I was doing this my boss was charging the client 175
an hour and speed of programming was considered MUCH more important than
speed of execution.

The way I look at it, when I started programming 30 years ago systems were
millions of times slower, and in another 30 years they'll be so stinking
fast that coding for speed will go the way of the Suchomimus and the
Iguanodon!

Like...systems will be accessing data at quad-terabytes per nanosecond over
wireless photonic motherboards the size of a dime.you know?

http://www.dinosauria.com/dml/dmlf.htm

Allen

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] Behalf Of George Gallen
Sent: Thursday, October 06, 2005 11:11
To: u2-users@listserver.u2ug.org
Subject: [U2] OPEN vs TRANS


Is there any savings on using TRANS() vs
   an OPEN at the top and a READ in the program
   (Assuming I am only reading 1 record 1 time)

This is using UV10

George
---
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/
---
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/


RE: [U2] OPEN vs TRANS

2005-10-07 Thread Glenn Herbert
   You  are  100% correct and this is a known issue (to me anyways).  The
   cache is only flushed when exiting the account or when you return back
   to  TCL.   Unfortunately,  there is no direct way to call the internal
   transclear() function.

   __

   From: [EMAIL PROTECTED]
   [mailto:[EMAIL PROTECTED]  On  Behalf Of
   [EMAIL PROTECTED]
   Sent: Friday, October 07, 2005 11:22 AM
   To: u2-users@listserver.u2ug.org
   Subject: RE: [U2] OPEN vs TRANS

   Our system has many accounts with, basically, the same file names,
   layouts, etc. We found a problem with using the translate rather than
   open/read in programs.
   If  a  program  logs  from account to account and accesses info with a
   trans,
   the  trans  doesn't always open and read the file in the new account's
   file,
   rather the trans retrieves the info from an earlier account.
   Am I right is supposing this phenomena is due to the file and record
   having  the  same  ID and logging to another account doesn't flush the
   cache?
   Thanks,
   Bruce
   Bruce M Neylon
   Health Care Management Group
   Glenn Herbert
   Sent by: [EMAIL PROTECTED]
   10/06/2005 07:53 PM
   Please respond to u2-users
   To: [EMAIL PROTECTED], u2-users@listserver.u2ug.org
   cc:
   Subject: RE: [U2] OPEN vs TRANS
   The vlist should show a call to Ftrans, which basically does an OPEN
   and a READ, and caches both for later reuse (subsequent reads on a
   file open'd earlier don't waste the time of the open). I also believe
   that the file cache is for 10 files, then the oldest gets closed, and
   the record cache is for 50 records between all open files. If you do
   multiple TRANS ops on the same file same record, but different fields,
   you only pay the cost of search for the field (assuming your file and
   record are still IN the cache!)
   Hope this helps
   Glenn
   ---
   u2-users mailing list
   u2-users@listserver.u2ug.org
   To unsubscribe please visit http://listserver.u2ug.org/
   ---
   u2-users mailing list
   u2-users@listserver.u2ug.org
   To unsubscribe please visit http://listserver.u2ug.org/
---
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/


RE: [U2] OPEN vs TRANS

2005-10-07 Thread BNeylon
Our system has many accounts with, basically, the same file names, 
layouts, etc.  We found a problem with using the translate rather than 
open/read in programs. 
If a program logs from account to account and accesses info with a trans, 
the trans doesn't always open and read the file in the new account's file, 
rather the trans retrieves the info from an earlier account.
Am I right is supposing this phenomena is due to the file and record 
having the same ID and logging to another account doesn't flush the cache? 
 
Thanks,
Bruce

Bruce M Neylon
Health Care Management Group 





Glenn Herbert <[EMAIL PROTECTED]>
Sent by: [EMAIL PROTECTED]
10/06/2005 07:53 PM
Please respond to u2-users

 
To: [EMAIL PROTECTED], u2-users@listserver.u2ug.org
cc: 
        Subject:    RE: [U2] OPEN vs TRANS

   The  vlist  should show a call to Ftrans, which basically does an OPEN
   and  a  READ,  and  caches both for later reuse (subsequent reads on a
   file open'd earlier don't waste the time of the open).  I also believe
   that  the file cache is for 10 files, then the oldest gets closed, and
   the record cache is for 50 records between all open files.   If you do
   multiple TRANS ops on the same file same record, but different fields,
   you  only pay the cost of search for the field (assuming your file and
   record are still IN the cache!)

   Hope this helps

   Glenn 
---
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/
---
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/


RE: [U2] OPEN vs TRANS

2005-10-07 Thread Hennessey, Mark F.
When I use TRANS in i-descriptors and I need more than one field, I grab the
whole @RECORD, then EXTRACT multiple times.  I'm not really a programmer
(obviously), but wouldn't the same hold true in a program?

...  One thing that kills me is seeing I-descriptors that do something like
'... IF(TRANS(ORDERFILE,@ID,1,'X')) EQ '' THEN 'NO FIELD 1' ELSE
TRANS(ORDERFILE,@ID,1,'X')...'

 -Original Message-
From: Glenn Herbert [mailto:[EMAIL PROTECTED]
Sent: Thursday, October 06, 2005 7:54 PM
To: Hennessey, Mark F.; u2-users@listserver.u2ug.org
Subject: RE: [U2] OPEN vs TRANS



The vlist should show a call to Ftrans, which basically does an OPEN and a
READ, and caches both for later reuse (subsequent reads on a file open'd
earlier don't waste the time of the open).  I also believe that the file cache
is for 10 files, then the oldest gets closed, and the record cache is for 50
records between all open files.   If you do multiple TRANS ops on the same
file same record, but different fields, you only pay the cost of search for
the field (assuming your file and record are still IN the cache!)



Hope this helps

Glenn
---
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/


Re: [U2] OPEN vs. TRANS

2005-10-06 Thread Mats Carlid

Bob Woodward wrote:


I believe, for the most part, you are correct, but doesn't TRANS also do
some work with the system delimiters?  Such as a LOWER() or RAISE()
function on the data that is returned? 


TRANS does indeed return the field  LOWER-ed.

-- mats


Something in the back of my head
is hitting me on this but it may be if you're going to be accessing more
than one field from the same record.  In that case I'd always do an
OPEN/READ, but I'd always try to limit the OPEN statement, especially if
you're calling this subroutine from a DICT entry.  


Bob W

---
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/


RE: [U2] OPEN vs. TRANS

2005-10-06 Thread Bob Woodward
I believe, for the most part, you are correct, but doesn't TRANS also do
some work with the system delimiters?  Such as a LOWER() or RAISE()
function on the data that is returned?  Something in the back of my head
is hitting me on this but it may be if you're going to be accessing more
than one field from the same record.  In that case I'd always do an
OPEN/READ, but I'd always try to limit the OPEN statement, especially if
you're calling this subroutine from a DICT entry.  

Bob W

> -Original Message-
> From: [EMAIL PROTECTED] [mailto:owner-u2-
> [EMAIL PROTECTED] On Behalf Of Glenn Herbert
> Sent: Thursday, October 06, 2005 4:54 PM
> To: [EMAIL PROTECTED]; u2-users@listserver.u2ug.org
> Subject: RE: [U2] OPEN vs TRANS
> 
>The  vlist  should show a call to Ftrans, which basically does an
OPEN
>and  a  READ,  and  caches both for later reuse (subsequent reads
on a
>file open'd earlier don't waste the time of the open).  I also
believe
>that  the file cache is for 10 files, then the oldest gets closed,
and
>the record cache is for 50 records between all open files.   If you
do
>multiple TRANS ops on the same file same record, but different
fields,
>you  only pay the cost of search for the field (assuming your file
and
>record are still IN the cache!)
> 
>Hope this helps
> 
>Glenn
> 
>
__
> 
>From: [EMAIL PROTECTED]
>[mailto:[EMAIL PROTECTED]  On  Behalf Of
"Hennessey,
>Mark F." <[EMAIL PROTECTED]>
>Sent: Thursday, October 06, 2005 2:55 PM
>To: u2-users@listserver.u2ug.org
>Subject: RE: [U2] OPEN vs TRANS
> 
>I  think you could test this by writing the code both ways, then
doing
>a VLIST to see what actual basic object code would be.
>-Original Message-
>From: George Gallen [mailto:[EMAIL PROTECTED]
>Sent: Thursday, October 06, 2005 2:11 PM
>To: u2-users@listserver.u2ug.org
>Subject: [U2] OPEN vs TRANS
>Is there any savings on using TRANS() vs
>an OPEN at the top and a READ in the program
>(Assuming I am only reading 1 record 1 time)
>This is using UV10
>George
---
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/


RE: [U2] OPEN vs TRANS

2005-10-06 Thread Ross Ferris
The saving is in the typing that doesn't have to be done with an
OPEN _blah
READ _foo 

Vs the TRANS  The COST of this saving may be in the readability of
the code and long term maintenance. If you adopted TRANS as a "standard"
then I'd say go for it - if not, why complicate your life

(I believe if there were multiple file reads, then READ would outperform
TRANS)

Ross Ferris
Stamina Software
Visage > Better by Design!
 

>-Original Message-
>From: [EMAIL PROTECTED] 
>[mailto:[EMAIL PROTECTED] On Behalf Of 
>Hennessey, Mark F.
>Sent: Friday, 7 October 2005 4:55 AM
>To: u2-users@listserver.u2ug.org
>Subject: RE: [U2] OPEN vs TRANS
>
>I think you could test this by writing the code both ways, 
>then doing a VLIST to see what actual basic object code would be.
>
>-Original Message-
>From: George Gallen [mailto:[EMAIL PROTECTED]
>Sent: Thursday, October 06, 2005 2:11 PM
>To: u2-users@listserver.u2ug.org
>Subject: [U2] OPEN vs TRANS
>
>
>Is there any savings on using TRANS() vs
>   an OPEN at the top and a READ in the program
>   (Assuming I am only reading 1 record 1 time)
>
>This is using UV10
>
>George
>---
>u2-users mailing list
>u2-users@listserver.u2ug.org
>To unsubscribe please visit http://listserver.u2ug.org/
>---
>u2-users mailing list
>u2-users@listserver.u2ug.org
>To unsubscribe please visit http://listserver.u2ug.org/
---
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/


RE: [U2] OPEN vs TRANS

2005-10-06 Thread Glenn Herbert
   The  vlist  should show a call to Ftrans, which basically does an OPEN
   and  a  READ,  and  caches both for later reuse (subsequent reads on a
   file open'd earlier don't waste the time of the open).  I also believe
   that  the file cache is for 10 files, then the oldest gets closed, and
   the record cache is for 50 records between all open files.   If you do
   multiple TRANS ops on the same file same record, but different fields,
   you  only pay the cost of search for the field (assuming your file and
   record are still IN the cache!)

   Hope this helps

   Glenn

   __

   From: [EMAIL PROTECTED]
   [mailto:[EMAIL PROTECTED]  On  Behalf Of "Hennessey,
   Mark F." <[EMAIL PROTECTED]>
   Sent: Thursday, October 06, 2005 2:55 PM
   To: u2-users@listserver.u2ug.org
   Subject: RE: [U2] OPEN vs TRANS

   I  think you could test this by writing the code both ways, then doing
   a VLIST to see what actual basic object code would be.
   -Original Message-
   From: George Gallen [mailto:[EMAIL PROTECTED]
   Sent: Thursday, October 06, 2005 2:11 PM
   To: u2-users@listserver.u2ug.org
   Subject: [U2] OPEN vs TRANS
   Is there any savings on using TRANS() vs
   an OPEN at the top and a READ in the program
   (Assuming I am only reading 1 record 1 time)
   This is using UV10
   George
   ---
   u2-users mailing list
   u2-users@listserver.u2ug.org
   To unsubscribe please visit http://listserver.u2ug.org/
   ---
   u2-users mailing list
   u2-users@listserver.u2ug.org
   To unsubscribe please visit http://listserver.u2ug.org/
---
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/


RE: [U2] OPEN vs TRANS

2005-10-06 Thread Hennessey, Mark F.
I think you could test this by writing the code both ways, then doing a VLIST 
to see what actual basic object code would be.

-Original Message-
From: George Gallen [mailto:[EMAIL PROTECTED]
Sent: Thursday, October 06, 2005 2:11 PM
To: u2-users@listserver.u2ug.org
Subject: [U2] OPEN vs TRANS


Is there any savings on using TRANS() vs
   an OPEN at the top and a READ in the program
   (Assuming I am only reading 1 record 1 time)

This is using UV10

George
---
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/
---
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/