How can we code a program such that we will never get a
MAPFAIL error?



How can we code a program such that we will never get a MAPFAIL error?..

Answer / rakesh

Normally MAPFAIL just indicates that no data has ben entered in any of the fields, and thus the MDT-bit is not set in the fileds attribute-byte. CICS issues a "Read Modified" 3270-command, and receives data from fields that has the MDT-bit set. When you get MAPFAIL, this just tells you that no field has been modified, an really is "normal".
In program logic you have to check if data has been entered in mandatory fileds. The result may vary, and is a result of users action. Zero or many fileds may have been modified.
In your program logic you should FIRST check for invalid PF/PA/Clear-keys, and ONLY do a Receive Map after the check. There is no need to do a Receive Map if the user pressed the Clear or a PA-key, as an example. The EIBAID contains the value for the key pressed to initiate this pseudoconversation - even without a Receive Map.
If you use Resp Option, coding RESP(ws-variable) in your Receive Map, you can eliminate the Mapfail problem.

Is This Answer Correct ?    2 Yes 1 No

Post New Answer

More CICS Interview Questions

Which command is used to release a record on which exclusive control is gained?

1 Answers  


Explain processing program table(ppt)?

0 Answers  


What is an ASRA abend ?

3 Answers   IBM,


What are the parameters that you have to give when you are using the CSSN transaction?

3 Answers  


What is the error condition that is set when the file specified in the NAME option is not in the FCT?

1 Answers   UHG,


What is the cics command that is used to access current date and time?

0 Answers  


How is Telon(CA-Telon) used to build map?

0 Answers  


Hi Folks, In the Map, one field is having attribute FSET. I want to FSET OFF of that field through program. Can any body let me know the process? Thanks Praveen

3 Answers  


Explain how pa key is different from pf key?

0 Answers  


how a data in physical and symbolic map gets treated? Since the physical map is much concerned about the screen alignment and the field positions, how the values entered in the field which has PICIN or PICOUT clause in Physical map gets treated? Does that mean datas recieved or sent to the physical map should be constant? How does the data in Symbolic map gets converted with 5suffix namely F,L,A,I and O. For example EMPNO is treated as EMPNOI, EMPNOO, EMPNOA, EMPNOL and EMPNOF. how does this happen in symbolic map. Please provide your inputs on the above and kindly correct me if I am wrong.

0 Answers   HP,


Can you define ppt and what are its uses?

0 Answers  


What is MDT? What are FSET, FRSET ?

3 Answers   IBM,


Categories