how to code the following map using occours clause?
all the three fields have different length.
ename eno addr

1) _______ _________ __________
2) _______ _________ __________
3) _______ _________ __________
4) _______ _________ __________
5) _______ _________ __________
6) _______ _________ __________


Answer Posted / sandeep

code BMS macro with all the fields I mean with all the
occurances. for example

give the first occurence field name as ename1, eno1,addrr1
and second line field as

ename2, eno2,addrr2 and respectively for all the six
occurences. Once you generate a map the symbolic map
consists of all the fields it looks like below (coded for
output field i.e Field+O only)


03 filler picture x(2)
03 ename1a pic x
03 ename1o pic x(10)
03 filler pic x(2)
03 eno1a pic x
03 enoO pic x(10)
03 filler pic x(2)
03 addr1a pic x
03 addrO pic x(10)
03 filler picture x(2)
03 ename2a pic x
03 ename2o pic x(10)
.
.
etc

You need to modify above symbolic map as shown below

02 employee OCCURS 6.
03 enamea pic x
03 enameo pic x(10)
03 filler pic x(2)
03 enoa pic x
03 enoO pic x(10)
03 filler pic x(2)
03 addra pic x
03 addrO pic x(10)

You can also give Occurs clause in BMS macro
Ex:
TELNO DFHMDF POS=(7,1),LENGTH=9,ATTRB=NORM,OCCURS=40
The description of these fields in the symbolic map looks
like this in COBOL:

02 TELNOG OCCURS 40.
03 FILLER PICTURE X(2).
03 TELNOA PICTURE X.
03 TELNOO PIC X(9).

Is This Answer Correct ?    13 Yes 4 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

In case if the user inputs the characters which turn out to be uppercase, then what is the procedure to close that condition?

759


Explain how do you delete item 3 in a five-item tsq?

698


What is the comaera (communication area)?

857


Explain the uses that are associated to tsq and tdq ?

833


How do you use altindxs in batch, cics programs?

779


How errors are handled in CICS programs?

831


What is an mdt (modified data tag)?

793


What are the cics transactions?

761


when an apllication is invoked via the exec cics start command with the from option, how does the application gain access to the common area?

846


With the use of an alternate index, how is a VSAM file accessed?

829


In a CICS program, how will you read a VSAM file?

870


What are the common cics service programs and explain their usage?

789


Explain the difference between a symbolic map and physical map?

774


Can you define mdt?

853


Define cebr?

756