Why is GETMAIN command needed?? Will program not work if we
do not give GETMAIN?

Answers were Sorted based on User's Feedback



Why is GETMAIN command needed?? Will program not work if we do not give GETMAIN?..

Answer / pradeep kumar

Getmain is a named memory for the Linkage Section variables
in the CICS program. The variables are passed to the memory
using SET command. The SET command can be used only for 01
and 77 level group items.

Program will work even if GETMAIN is not coded, because the
memory will be allocated automatically by the compiler, but
if the programmer needs memory space for the Linkage
Section Variables explicitly, then he/she can use GETMAIN
to allocate memory and FREEMAIN is used to freeout the
allocated memory.

Is This Answer Correct ?    5 Yes 0 No

Why is GETMAIN command needed?? Will program not work if we do not give GETMAIN?..

Answer / kingmanish

Hi Pradeep. What will happen if the GETMAIN command is issued and memory is not available.
Will the program abend or it will keep trying until it gets memory.
also if the memory is not available for a long time Will it get time out??

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More CICS Interview Questions

Can you define multiple maps in a BMS mapset?

3 Answers   Cap Gemini, IBM,


Is it possible start a transaction CICS from job Batch? How do it?

5 Answers   CSC,


Explain how do you set the mdt option to on status, even if data is not entered?

0 Answers  


What is journal recovery?

0 Answers  


What is the tcp in the cisc?

0 Answers  


What are the classifications of the cics program?

0 Answers  


How do you enter into cics region and how many regions available?

1 Answers   Cap Gemini,


Highlight the difference between a symbolic map and physical map?

0 Answers  


What is the difference between using the READ command with INTO option and SET option?

2 Answers   IBM,


I just want to ask why does the variable I passed in a dclgen of sql that has a data type of varchar which has a maximum length is 250 is truncated,, Here is the code.. DCLGEN of rsauud01 table 01 dataarea 43 data-area-len pic s9(4). 43 data-area-text pic x(250). MYVARIABLE. 01 DATAAREA1 pic x(250). move 250 to data-area-len of dataarea of rsauud01 MOVE DATA-AREA1 TO data-area-text of dataarea of rsauud01 --- but it is always trucated everytime I insert it in the table by the way it is a cobol-cics program

2 Answers  


Name and explain some common CICS abend codes?

2 Answers   HSBC,


What is the meaning and use of the EIBAID field?

4 Answers  


Categories