Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

(RPG) Using Control Breaks with Exterally Defined Files

476 views
Skip to first unread message

Paul Bomboy

unread,
Jan 29, 2000, 3:00:00 AM1/29/00
to
If anyone knows an easy way to use Control Breaks L1-L9 with an
externally described file, please let me know.

I have tried may different ways. (i.e. Data Structures, Etc)

I cannot seem to figure out what I am doing wrong..

Thanks in advance

Peter.Schalber

unread,
Jan 30, 2000, 3:00:00 AM1/30/00
to
Hi,
which problems do you have ?

Peter

"Paul Bomboy" <pr...@surfshop.net> wrote in message news:389398F9...@surfshop.net...

Bill Wragg

unread,
Jan 30, 2000, 3:00:00 AM1/30/00
to
Hi,

In the Input specs.

IRecfmt
I external fld name
external fld name L1
I external fld name
external fld name L2


This will override and/or rename the external field name and place the level
indicators on them.
Of course the file has to be defined as Primary.
--
Bill Wragg
Systems Consultant
Chatham, Ontario, Canada

John Johnson

unread,
Jan 30, 2000, 3:00:00 AM1/30/00
to
Include a couple of "I" specs for the file. The first has the record format
name. The second has the externally described field name and the control
break indicator.

For a file called FILEA with a record format of FILEAR and a field name of
FIELDA:

FFILEA IP E K DISK
IFILEAR
I FIELDA L1

Hope this helps.

Peter Sault

unread,
Jan 31, 2000, 3:00:00 AM1/31/00
to
In article <94924695...@dnews.wincom.net>,
"Bill Wragg" <wr...@ciaccess.com> wrote:

> Of course the file has to be defined as Primary.

More correctly, the file must be read using the RPG cycle. It may
therefore be primary or secondary.


Sent via Deja.com http://www.deja.com/
Before you buy.

JimJink...@yahoo.com

unread,
Jan 31, 2000, 3:00:00 AM1/31/00
to
It can also be Fully Procedural, as long as the L1-L9 indicators are
SETOF just before the READ.

On Mon, 31 Jan 2000 03:32:02 GMT, Peter Sault <gom...@my-deja.com>
wrote:

Ken S.

unread,
Jan 31, 2000, 3:00:00 AM1/31/00
to
Hi Jim -

On Mon, 31 Jan 2000 09:39:56 GMT, JimJink...@yahoo.com wrote:

>It can also be Fully Procedural, as long as the L1-L9 indicators are
>SETOF just before the READ.

Seeing how as the manuals state explicitly that level indicators can
be used only on primary and secondary files, and also state
specifically that they canNOT be used on full procedural files
(section 1.4.1.3.1 in the V4R4 ILE RPG manual and section 3.1.3.1 in
the V4R4 RPG/400 manual), and seeing how as both of those compilers
reject trying to use level indicators on full procedural files (I
tried it); on what basis do you make your statement??????

Ken
Opinions expressed are my own and do not necessarily represent the views of my employer or anyone else.

JimJink...@yahoo.com

unread,
Feb 1, 2000, 3:00:00 AM2/1/00
to

> on what basis do you make your statement??????

A bad memory

dic...@attglobal.net

unread,
Feb 13, 2000, 3:00:00 AM2/13/00
to
Control Breaks are indicated in the same manner for externally defined files as they are for copy books (// COPY) ie.

0001.00      H
0003.00      FMAP010  UP  E                    DISK
0004.00      FMAP050  IF  E           K        DISK
0005.00      FQSYSPRT O   F      85     OF     PRINTER
0006.00      E                    REP    15  15  5
0007.00      IMAP010R
0008.00      I                                              MA1022L1
Where MA1022 is a field within file MAP010 format MAP010R.
Okay?
DICKJ
"Peter.Schalber" wrote:

Hi,
 which problems do you have ?

Peter

"Paul Bomboy" <pr...@surfshop.net> wrote in message news:389398F9...@surfshop.net...

balu...@gmail.com

unread,
Aug 14, 2015, 6:47:36 AM8/14/15
to
On Saturday, January 29, 2000 at 1:30:00 PM UTC+5:30, Paul Bomboy wrote:
> If anyone knows an easy way to use Control Breaks L1-L9 with an
> externally described file, please let me know.
>
> I have tried may different ways. (i.e. Data Structures, Etc)
>
> I cannot seem to figure out what I am doing wrong..
>
> Thanks in advance

Hi any one post the simple RPG PGM for level break indicator

CRPence

unread,
Aug 15, 2015, 12:09:08 PM8/15/15
to
FWiW the web search
[https://www.google.com/search?q=rpg+level+break+example]
yielded [http://www.jaymoseley.com/hercules/rpgtutor/rpg016.htm], among
presumably, several others.

--
Regards, Chuck

intan...@gmail.com

unread,
Feb 26, 2019, 2:18:58 AM2/26/19
to
HI DO YOU HAVE A SIMPLE EXAMPLE FOR LEVEL BREAK IN EXTERNALLY DESC PRINTER FILE?

Buck

unread,
Feb 26, 2019, 8:01:19 PM2/26/19
to
On Tuesday, February 26, 2019 at 2:18:58 AM UTC-5, intan...@gmail.com wrote:

> HI DO YOU HAVE A SIMPLE EXAMPLE FOR LEVEL BREAK IN EXTERNALLY DESC PRINTER FILE?

There is nothing special about level breaks and printer files. Just WRITE the appropriate record format at the appropriate time, for example

if *inl1;
write l1Detail;
endif;

Total time is a bit harder, because if can't be done in /free; you'll need a genuine C-specification:

Cl1 write l1Total

Hope that helps.
--buck
Message has been deleted

Jonathan Bailey

unread,
Mar 13, 2019, 8:56:24 AM3/13/19
to
On Wednesday, 13 March 2019 03:03:17 UTC, intan...@gmail.com wrote:
> Can we have statement before do loop ? Im putting 01 at conditioning indicator and do at operation. When I try to debug after the enddo it will go back to the statement before the do. Can i know why ?

I personally never liked conditioning indicators on if or do statements. What does it mean? Turn only the condition on or off or the whole code block?
When computers only had a few kilobytes of memory this form of programming was well matched to the limited resources, but nowadays you should probably re-write from scratch.

One thing which I have seen a lot of is that the program object and source code do not match. This often makes the line numbers not line up, and so the program loops back to a different line in the program source. If you dont know how do "dspobjd library/program *pgm" and note the change date & time. Then "dspfd library/sourcefile" and note the date & time of the member.
If you are using modules then dsppgm will give you info on these.

My advice, post your question and a snippet of your code into a new thread. This might entice people to look at it instead of spotting its a 19 year old thread and going somewhere else.

Jonathan
0 new messages