# ABMA: Invalid data length on a BMS request

Source: https://wndsoftware.com/mainframe-errors/abma

### ABMA: Invalid data length on a BMS request

An ABMA abend means a BMS output request gave CICS a data length it can't use. The terminal I/O area (TIOA) holding the output had a data length of zero, or one larger than the storage it sits in allows.


#### Other names for this code

Also written as `ABMA abend`, `CICS ABMA`, `abend ABMA`, `BMS ABMA`, `ABMA SEND TEXT`.


### What it means

When a program sends output through BMS, CICS works with a terminal input/output area, the TIOA. The TIOA records how much data it holds and how much storage it occupies. Before BMS builds the output, it checks the data length. The length has to be more than zero. It also has to fit in the storage that was allocated, which IBM measures as the storage accounting length less 12 bytes for the TIOA's own control fields.

If the check fails, CICS ends the transaction with ABMA and takes a transaction dump.

ABMA doesn't mean BMS is broken. The length came from the program, either from an option on the command or from a value the program worked out. So the search starts in the program that issued the request, and in the data that fed the length.


### Common causes

- A length field that was never set, or that was set from an empty input, so a length of zero reached BMS.
- A length worked out at run time that came out far too big, for example when a subtraction went negative or a binary field overflowed.
- A length that is bigger than the area named in FROM, for example after the area was made smaller but the length constant wasn't changed.
- A storage overlay. Another part of the program wrote over the length field or the area that holds the output.


### How to find the problem

- The region's message log shows the transaction and program with abend ABMA, and CICS takes a transaction dump.
- Find the SEND TEXT, SEND MAP or SEND PAGE that failed. CEDF shows the FROM and LENGTH options before CICS runs the command, and a zero or huge length is easy to spot there.
- In the transaction dump, find the TIOA. Compare its data length field (TIOATDL) with its storage accounting length (TIOASAL) to see which limit was broken.
- Trace the length back through the program to where it was set, and check whether the data that fed it can be empty or out of range.


### How to fix it

- Set LENGTH from the real size of the data, and test it before the SEND. If there's nothing to send, skip the command or send a short message instead.
- Give length fields a starting value, and define LENGTH as a binary halfword, for example PIC S9(4) COMP in COBOL.
- If the length is calculated, check that it is above zero and no bigger than the FROM area before the command runs.
- If the length looks right in the source but is wrong in the dump, look for a storage overlay, such as a subscript out of range, in the code that ran just before the SEND.


### IBM documentation

[IBM documentation: ABMA](https://www.ibm.com/docs/en/cics-ts/6.x?topic=codes-abma). Use the documentation for your installed release.

[Report a correction to WND Software](https://wndsoftware.com/contact#message).

Last reviewed 2026-10-18 by the WND Software team. Written in our own words. For the full reference, check IBM’s CICS documentation for your release.


### Related codes

[ABMB BMS cursor position past the screen Read →](https://wndsoftware.com/mainframe-errors/abmb)
[ABM0 BMS map not found Read →](https://wndsoftware.com/mainframe-errors/abm0)
[AEIV LENGERR not handled Read →](https://wndsoftware.com/mainframe-errors/aeiv)
[ASRA Program check in a CICS transaction Read →](https://wndsoftware.com/mainframe-errors/asra)
[AEYD Invalid output address caught by command protection Read →](https://wndsoftware.com/mainframe-errors/aeyd)

### Questions


#### Is ABMA a CICS problem?

Rarely. The length comes from the program, so the fix is nearly always in the program that issued the BMS request.


#### Why does ABMA happen only now and then?

The length often depends on the data. A message that is empty only in some cases, or a length computed from input, fails only when that case comes up.


#### Which fields matter in the dump?

The TIOA's data length (TIOATDL) and its storage accounting length (TIOASAL). A data length of zero, or one that doesn't fit in the storage, is what BMS rejected.

[CICS transaction abends](https://wndsoftware.com/mainframe-errors/cics-abends) · [ABM0](https://wndsoftware.com/mainframe-errors/abm0) · [ABMB](https://wndsoftware.com/mainframe-errors/abmb)

[← All error codes](https://wndsoftware.com/mainframe-errors/)
