Re: [U2] Multiple OPEN statements

2005-04-16 Thread Mark Johnson
How early Microdata. I have one client with November 1975 written source
code and it's the traditional
OPEN FILE1 TO F.FILE1 ELSE PRINT ELONGATED VERBOSE ERRORMESSAGE
OPEN FILE2 TO F.FILE2 ELSE PRINT ELONGATED VERBOSE ERRORMESSAGE
for their core programs, opening dozens of files.

Thanks.

- Original Message -
From: Roger Glenfield [EMAIL PROTECTED]
To: u2-users@listserver.u2ug.org
Sent: Friday, April 15, 2005 10:29 PM
Subject: Re: [U2] Multiple OPEN statements


 Probably a left over.  Way back in early Microdata.  You could only open
 one file at a time.  There was no TO clause.  You had the file opened.
 If you wanted to access another file, you had to close the current one
 and open the next.

 Kevin used Dartmouth as his base, so think pre-Micro$oft.

 Roger
 Mark Johnson wrote:

 Is this CLOSE thing a new thing. Haven't seen or heard of it in a quarter
of
 a century. I know it's in MS Basic(s).
 - Original Message -
 From: Don Kibbey [EMAIL PROTECTED]
 To: u2-users@listserver.u2ug.org
 Sent: Friday, April 15, 2005 7:22 AM
 Subject: Re: [U2] Multiple OPEN statements
 
 
 
 
 That programmer was probably squaked at for not closing a file or two.
  Then he/she found a way to insure that would be caught next time by
 the compiler.
 ---
 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/
---
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/


Re: [U2] Hold-file to CSV

2005-04-16 Thread Mark Johnson
The whole premise was to use the existing reports that are presently
designed and not re-engineer them.

Like many systems, this one is full of finished reports (both english and
databasic) and the object is to send them to the hold-file and convert from
there. I don't want to re-invent the report generation logic, just use the
hold files.

Thanks


- Original Message -
From: Kate Stanton [EMAIL PROTECTED]
To: u2-users@listserver.u2ug.org
Sent: Friday, April 15, 2005 6:51 PM
Subject: Re: [U2] Hold-file to CSV


 Have you thought of using REFORMAT instead of SORT, so the data is easier
to
 handle?  I agree, tabs would be better than commas as delimiters.

 - Original Message -
 From: Mark Johnson [EMAIL PROTECTED]
 To: u2-users@listserver.u2ug.org
 Sent: Friday, April 15, 2005 2:15 PM
 Subject: [U2] Hold-file to CSV


  I'm at the threshold of wanting (needing) to convert print jobs in the
  HOLD
  (or PEQS if you really must know) file into CSV's. This does not mean
  re-generating the reports, rather digesting the held print job,
  identifying
  the header, removing the redundant headers and identifying the column
  positions into a CSV for obvious downstream purposes.
 
  I'm half way through writing a parsing program and wondered if there
were
  any
  other suggestions.
 
  Thanks in advance.
  Mark Johnson
  ---
  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] Multiple OPEN statements

2005-04-16 Thread Roger Glenfield
Can't say for sure.  I remember seeing it in one of the old programs 
that I had to work on in 1976/77.

So I'm guessing very early Basic.  After all, as we all know.  Kevin 
only wanted to get a football program running.  So he probably didn't 
worry that much about data files.

Roger
Mark Johnson wrote:
How early Microdata. I have one client with November 1975 written source
code and it's the traditional
OPEN FILE1 TO F.FILE1 ELSE PRINT ELONGATED VERBOSE ERRORMESSAGE
OPEN FILE2 TO F.FILE2 ELSE PRINT ELONGATED VERBOSE ERRORMESSAGE
for their core programs, opening dozens of files.
Thanks.
---
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/


Re: [U2] Hold-file to CSV

2005-04-16 Thread Roger Glenfield
Monarch from Datawatch.  Converts report files into data.
Mark Johnson wrote:
The whole premise was to use the existing reports that are presently
designed and not re-engineer them.
Like many systems, this one is full of finished reports (both english and
databasic) and the object is to send them to the hold-file and convert from
there. I don't want to re-invent the report generation logic, just use the
hold files.
Thanks
---
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/


Re: [U2] Multiple OPEN statements

2005-04-16 Thread Allen Bell
Who's Kevin?
Do you mean Ken Simms?

Roger Glenfield wrote:
Can't say for sure.  I remember seeing it in one of the old programs 
that I had to work on in 1976/77.

So I'm guessing very early Basic.  After all, as we all know.  Kevin 
only wanted to get a football program running.  So he probably didn't 
worry that much about data files.

Roger
Mark Johnson wrote:
How early Microdata. I have one client with November 1975 written source
code and it's the traditional
OPEN FILE1 TO F.FILE1 ELSE PRINT ELONGATED VERBOSE ERRORMESSAGE
OPEN FILE2 TO F.FILE2 ELSE PRINT ELONGATED VERBOSE ERRORMESSAGE
for their core programs, opening dozens of files.
Thanks.
---
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] Multiple OPEN statements

2005-04-16 Thread Bill H.
Mark:

I would say this is legitimate if one is reading from, or opening, a
prioritized list of files.  For instance, say I want to get a configuration
parameter and want to:

READ ParameterValue FROM ParameterFile.Fv, ParameterId THEN...ELSE...

This parameter can come from any of several files already prioritized, say:

LOCAL_PARAMETERS
GLOBAL_PARAMETERS

Then one might:

OPEN 'LOCAL_PARAMETERS' TO ParameterFile.Fv ELSE
   OPEN 'GLOBAL_PARAMETERS' TO ParameterFile.Fv THEN...ELSE...
END

Just a thought.  :-)

Bill

 -Original Message-
 From: [EMAIL PROTECTED] 
 [mailto:[EMAIL PROTECTED] On Behalf Of Mark Johnson
 Sent: Friday, April 15, 2005 7:00 PM
 To: u2-users@listserver.u2ug.org
 Subject: Re: [U2] Multiple OPEN statements
 
 Call me old-school but I prefer top-down OPEN file TO handle 
 ELSE STOP (sic) to get them all out of the way. Whether 1 or 
 50 files, the get all opened at the same time. If those 
 choose to have a CALL OPEN.FILES internal sub or named 
 commons, then that's also a respectable method.
 
 To have the main portion of the code be that indented only 
 makes maintenance later that much more difficult. Very, very 
 few people seem to label their END statements to indicate 
 what they're matched to.
 
 Upon further investigation (using that programmers initials) 
 i found that when there were 8 or more file, he did it in a 
 more top-down or sequential fashion. That introduces 2 forms 
 of coding for the same concept which is 1 form too many.
 
 That programmer is still at this client and uses the tired 
 response That's what I was taught when shown how hard it is 
 to follow all of those indents.
 Can't teach an old dog...
 
 my 1 cent
 - Original Message -
 From: Jerry Banker [EMAIL PROTECTED]
 To: u2-users@listserver.u2ug.org
 Sent: Friday, April 15, 2005 10:36 AM
 Subject: Re: [U2] Multiple OPEN statements
 
 
  - Original Message -
   From: Don Kibbey [EMAIL PROTECTED] You did mention 
 only a few 
   files display this type of syntax.  Perhaps said programmer was 
   shown the door
 
  I don't see why you would think that and frankly I'm surprised you 
  haven't come across this style of programming before. This style of 
  programming
 was
  taught in classrooms all over the country before the advent 
 of point 
  and click programming. It is a structured way of 
 programming based on 
  a logic
  sequence:
  What is the first file I need?
  OPEN FILE1 TO F.FILE1 THEN
  END ELSE PRINT CAN'T OPEN FILE1
  END
 
  Do I need another one?
  OPEN FILE1 TO F.FILE1 THEN
   OPEN FILE2 TO F.FILE2 THEN
   END ELSE PRINT CAN'T OPEN FILE2
  END ELSE PRINT CAN'T OPEN FILE1
  END
 
  And another?
  OPEN FILE1 TO F.FILE1 THEN
   OPEN FILE2 TO F.FILE2 THEN
   OPEN FILE3 TO F.FILE3 THEN
   END ELSE PRINT CAN'T OPEN FILE3
   END ELSE PRINT CAN'T OPEN FILE2
  END ELSE PRINT CAN'T OPEN FILE1
  END
 
  Now that I've got these open what do I do with them OPEN FILE1 TO 
  F.FILE1 THEN
   OPEN FILE2 TO F.FILE2 THEN
   OPEN FILE3 TO F.FILE3 THEN
   EOF=0
   LOOP READNEXT ID ELSE EOF=1 UNTIL EOF DO
   PROCESS, PROCESS, PROCESS
   REPEAT
   END ELSE PRINT CAN'T OPEN FILE3
   END ELSE PRINT CAN'T OPEN FILE2
  END ELSE PRINT CAN'T OPEN FILE1
  END
 
  Although when the gosub came out most programmers took the 
 center out 
  and put it into a separate subroutine.
  ---
  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] Multiple OPEN statements

2005-04-16 Thread Roger Glenfield
Senioritis has set in.  Yes Ken Simms.
Allen Bell wrote:
Who's Kevin?
Do you mean Ken Simms?
Roger Glenfield wrote:

Can't say for sure.  I remember seeing it in one of the old programs 
that I had to work on in 1976/77.

So I'm guessing very early Basic.  After all, as we all know.  Kevin 
only wanted to get a football program running.  So he probably didn't 
worry that much about data files.

Roger
Mark Johnson wrote:
How early Microdata. I have one client with November 1975 written 
source
code and it's the traditional
OPEN FILE1 TO F.FILE1 ELSE PRINT ELONGATED VERBOSE ERRORMESSAGE
OPEN FILE2 TO F.FILE2 ELSE PRINT ELONGATED VERBOSE ERRORMESSAGE
for their core programs, opening dozens of files.

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


Re: [U2] Multiple OPEN statements

2005-04-16 Thread Mark Johnson
This is not the first time people have referenced 'classrooms' where
programming was learned. Any specific classrooms where Pick/MV was taught
besides the VAR's seminars. Specifically a formal accredited environment for
Pick/MV and not just some left-over Pascal-era or contemporary teachings.

I would like to learn of these places that propogated some of the techniques
many endorse that may or not be embraced by others.

Thanks.

- Original Message -
From: Jerry Banker [EMAIL PROTECTED]
To: u2-users@listserver.u2ug.org
Sent: Friday, April 15, 2005 10:36 AM
Subject: Re: [U2] Multiple OPEN statements


 - Original Message -
  From: Don Kibbey [EMAIL PROTECTED]
  You did mention only a few files display this type of syntax.  Perhaps
  said programmer was shown the door

 I don't see why you would think that and frankly I'm surprised you haven't
 come across this style of programming before. This style of programming
was
 taught in classrooms all over the country before the advent of point and
 click programming. It is a structured way of programming based on a logic
 sequence:
 What is the first file I need?
 OPEN FILE1 TO F.FILE1 THEN
 END ELSE PRINT CAN'T OPEN FILE1
 END

 Do I need another one?
 OPEN FILE1 TO F.FILE1 THEN
  OPEN FILE2 TO F.FILE2 THEN
  END ELSE PRINT CAN'T OPEN FILE2
 END ELSE PRINT CAN'T OPEN FILE1
 END

 And another?
 OPEN FILE1 TO F.FILE1 THEN
  OPEN FILE2 TO F.FILE2 THEN
  OPEN FILE3 TO F.FILE3 THEN
  END ELSE PRINT CAN'T OPEN FILE3
  END ELSE PRINT CAN'T OPEN FILE2
 END ELSE PRINT CAN'T OPEN FILE1
 END

 Now that I've got these open what do I do with them
 OPEN FILE1 TO F.FILE1 THEN
  OPEN FILE2 TO F.FILE2 THEN
  OPEN FILE3 TO F.FILE3 THEN
  EOF=0
  LOOP READNEXT ID ELSE EOF=1 UNTIL EOF DO
  PROCESS, PROCESS, PROCESS
  REPEAT
  END ELSE PRINT CAN'T OPEN FILE3
  END ELSE PRINT CAN'T OPEN FILE2
 END ELSE PRINT CAN'T OPEN FILE1
 END

 Although when the gosub came out most programmers took the center out and
 put it into a separate subroutine.
 ---
 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] Multiple OPEN statements

2005-04-16 Thread Mark Johnson
That school is very diverse and doesn't offer any standardization that seems
to come up every once in a while on this forum. I appreciate the humor but
I'm really trying to learn where people are taught their Pick/MV techniques
(and defend them as gospel as they have been taught) as opposed to extending
one language's disciplines to another, namely Pick/MV.

Thanks
- Original Message -
From: Bruce Nichol [EMAIL PROTECTED]
To: u2-users@listserver.u2ug.org
Sent: Saturday, April 16, 2005 5:35 PM
Subject: Re: [U2] Multiple OPEN statements


 Goo'day,

 At 15:12 16/04/05 -0400, you wrote:

 This is not the first time people have referenced 'classrooms' where
 programming was learned. Any specific classrooms where Pick/MV was taught
 besides the VAR's seminars. Specifically a formal accredited environment
for
 Pick/MV and not just some left-over Pascal-era or contemporary teachings.
 
 I would like to learn of these places that propogated some of the
techniques
 many endorse that may or not be embraced by others.

 School of Hard Knocks?? There's a lot of the alumni out there.

 Thanks.
 
 - Original Message -
 From: Jerry Banker [EMAIL PROTECTED]
 To: u2-users@listserver.u2ug.org
 Sent: Friday, April 15, 2005 10:36 AM
 Subject: Re: [U2] Multiple OPEN statements
 
 
   - Original Message -
From: Don Kibbey [EMAIL PROTECTED]
You did mention only a few files display this type of syntax.
Perhaps
said programmer was shown the door
  
   I don't see why you would think that and frankly I'm surprised you
haven't
   come across this style of programming before. This style of
programming
 was
   taught in classrooms all over the country before the advent of point
and
   click programming. It is a structured way of programming based on a
logic
   sequence:
   What is the first file I need?
   OPEN FILE1 TO F.FILE1 THEN
   END ELSE PRINT CAN'T OPEN FILE1
   END
  
   Do I need another one?
   OPEN FILE1 TO F.FILE1 THEN
OPEN FILE2 TO F.FILE2 THEN
END ELSE PRINT CAN'T OPEN FILE2
   END ELSE PRINT CAN'T OPEN FILE1
   END
  
   And another?
   OPEN FILE1 TO F.FILE1 THEN
OPEN FILE2 TO F.FILE2 THEN
OPEN FILE3 TO F.FILE3 THEN
END ELSE PRINT CAN'T OPEN FILE3
END ELSE PRINT CAN'T OPEN FILE2
   END ELSE PRINT CAN'T OPEN FILE1
   END
  
   Now that I've got these open what do I do with them
   OPEN FILE1 TO F.FILE1 THEN
OPEN FILE2 TO F.FILE2 THEN
OPEN FILE3 TO F.FILE3 THEN
EOF=0
LOOP READNEXT ID ELSE EOF=1 UNTIL EOF DO
PROCESS, PROCESS, PROCESS
REPEAT
END ELSE PRINT CAN'T OPEN FILE3
END ELSE PRINT CAN'T OPEN FILE2
   END ELSE PRINT CAN'T OPEN FILE1
   END
  
   Although when the gosub came out most programmers took the center out
and
   put it into a separate subroutine.
   ---
   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/
 
 
 --
 No virus found in this incoming message.
 Checked by AVG Anti-Virus.
 Version: 7.0.308 / Virus Database: 266.9.13 - Release Date: 16/04/05
 
 
 
 
 --
 No virus found in this incoming message.
 Checked by AVG Anti-Virus.
 Version: 7.0.308 / Virus Database: 266.9.13 - Release Date: 16/04/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.308 / Virus Database: 266.9.13 - Release Date: 16/04/05




 --
 No virus found in this outgoing message.
 Checked by AVG Anti-Virus.
 Version: 7.0.308 / Virus Database: 266.9.13 - Release Date: 16/04/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] Multiple OPEN statements

2005-04-16 Thread Mark Johnson
Play on words, eh? There's just no official standards despite what many
imply.

- Original Message -
From: [EMAIL PROTECTED]
To: u2-users@listserver.u2ug.org
Sent: Saturday, April 16, 2005 8:19 PM
Subject: Re: [U2] Multiple OPEN statements


 Are you implying it would be better if programmers had no class ?
 Will

 In a message dated 4/16/2005 12:23:22 PM Pacific Daylight Time,
 [EMAIL PROTECTED] writes:


 
  This is not the first time people have referenced 'classrooms' where
  programming was learned. Any specific classrooms where Pick/MV was
taught
  besides the VAR's seminars. Specifically a formal accredited environment
for
  Pick/MV and not just some left-over Pascal-era or contemporary
teachings.
 ---
 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] Clarification on FOR...NEXT loops

2005-04-16 Thread jbutera
Taking advice from others on this list, I wrote a small program to compare
the execution time of extracting 1 elements from an MV list using
FOR/NEXT loop with 1,I delimiters verus using LOOP/WHILE with REMOVE.  I
should note this was done on Unidata 6.0.3.

All the previous comments are still valid - the LOOP/WHILE with REMOVE
beats a FOR/NEXT loop dramatically.  That is, on an MV list with 1
elements, FOR/NEXT took about 6500 milliseconds while LOOP/WHILE took 15
milliseconds (that's not a typo).

I ran the test 10+ times, I reversed the order of the tests and the result
was the same every time.

So if you need to loop over all elements in an MV list, the
LOOP/WHILE/REMOVE structure seems inherently more efficient than the
FOR/NEXT/1,I notation.

Jeff Butera, Ph.D.
Administrative Systems
Hampshire College
[EMAIL PROTECTED]
413-559-5556

...our behavior matters more than the beliefs that we profess.
Elizabeth Deutsch Earle
---
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/


Re: [U2] Hold-file to CSV

2005-04-16 Thread Mark Johnson
Wow, you pegged me properly. I once bought an SP-JOBS utility for D3
(allegedly) and it was somewhat incomplete and had a few bugs that it
basically taught me what to write and I wrote my own.

P.S. If not for anything else, Microdata had one of the best spooler
manager.

Thanks.

- Original Message -
From: [EMAIL PROTECTED]
To: u2-users@listserver.u2ug.org
Sent: Saturday, April 16, 2005 8:21 PM
Subject: Re: [U2] Hold-file to CSV


 In a message dated 4/16/2005 7:34:46 AM Pacific Daylight Time,
 [EMAIL PROTECTED] writes:


  Like many systems, this one is full of finished reports (both english
and
  databasic) and the object is to send them to the hold-file and convert
from
  there. I don't want to re-invent the report generation logic, just use
the
  hold files.

 Yes you have to parse the headers to determine the column start and stop
 positions and then scan the data to extract the column/row cell entries.
I know you're the type that likes to program it yourself instead of
buying
 it off-the-shelf :)
 Will
 ---
 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/