× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



I'm still trying to understand the relationship between these three things.

I'm pretty comfortable with the idea that having INDARA in your DDS requires
you to specify -SI in the ASSIGN TO clause of your display file SELECT
statement:

SELECT WRKSTN ASSIGN TO WORKSTATION-MYDISPLAY-SI
    ORGANIZATION TRANSACTION ACCESS DYNAMIC
    RELATIVE KEY IS SCR-KEY.

I can live with this.  Now comes the tricky bit, the indicators.

When I do NOT specify INDARA, the indicators are brought in as part of the
record formats.  For example, if I do a COPY-DDS-ALL-FORMATS, I would see an
two 05 level declarations for each record format, one for input and one for
output.  Under these would be 06 level declarations of the fields, as well
as an 06 level declaration for the indicators, like so:

05  MYRECORD-I   REDEFINES MYDISPLAY-MYRECORD.
    06 MYRECORD-I-INDIC.
         07 IN99             PIC 1  INDIC 99.
    06 CUSTOMER              PIC S9(6).
    06 NAME                  PIC X(10).

In this case, I assume that the MYRECORD-I-INDIC is the "default" indicator
area now, and is used whenever the MYRECORD format is read:

READ WRKSTN INTO MYRECORD-I

This syntax will automatically set IN99 in MYRECORD-I-INDIC based on the
appropriate DDS keyword.  Usually, this would be for an exit key, like F3.
So if F3 is pressed, IN99 is on.

Interestingly, it seems that I can override it by using the INDIC clause.  I
haven't actually tried it, but it compiles.

READ WRKSTN INTO MYRECORD-I INDIC SOMEOTHER-INDIC.

I suppose then that IN99 in SOMEOTHER-INDIC would get set on instead?  Would
IN99 in MYRECORD-I-INDIC not get updated?  Anyway, I assume one doesn't
normally code the INDIC clause when you're not using INDARA.


Things change with INDARA defined.  For starters, the indicators are not
brought in with COPY-DDS-ALL-FORMATS.  Instead, I only get the fields:

05  MYRECORD-I   REDEFINES MYDISPLAY-MYRECORD.
    06 CUSTOMER              PIC S9(6).
    06 NAME                  PIC X(10).

If I want to bring the indicators in automagically, I need to use a
COPY-DDS-ALL-FORMATS-INDIC, and get something like this:

05  MYRECORD-RECORD.
    06 MYRECORD-I-INDIC.
         07 IN99             PIC 1  INDIC 99.

Okay, I'm still hip with this.  However, my guess is that if you don't
specify an INDIC clause on an I/O statement, that no indicators will be
used.  Is this true?

READ WRKSTN INTO MYRECORD-I
(IN99 will not get set anywhere)

READ WRKSTN INTO MYRECORD-I USING MYRECORD-I-INDIC.
(IN99 will get set in MYRECORD-I-INDIC)

READ WRKSTN INTO MYRECORD-I USING SOMEOTHER-INDIC.
(IN99 will get set in SOMEOTHER-INDIC)

Yes?  No?  Comments?


Joe



As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.