Validate Storage Type Indicator for Stock Placement and Removal

Submitted by Jimbo on Thu, 11/14/2013 - 07:05
When loading the Warehouse Management view the Storage Type Indicator must exist in the
T305
table. The functional team can create it using the SPRO transaction (see image on the right).
Checking to ensure that the value is populated prevents a false-negative by not checking for a blank LGNUM
value. A simple SELECT SINGLE
operation determines if the value is present in the T305
table.
if IMMH1-LTKZE ne ''. select single LGNUM from T305 into BMMH1-LTKZE where LGNUM eq IMMH1-LTKZE. if sy-subrc ne 0. write: / IMMH1-MATNR, IMMH1-LTKZE, 'Invalid location (LTKZE).'. skip_transaction. endif. endif. if IMMH1-LTKZA ne ''. select single LGNUM from T305 into BMMH1-LTKZA where LGNUM eq IMMH1-LTKZA. if sy-subrc ne 0. write: / IMMH1-MATNR, IMMH1-LTKZA, 'Invalid location (LTKZA).'. skip_transaction. endif. endif.
Programming Language:
ABAP