SAP Plant Details Company code and Controlling Area for a Plant
To extract the Plant Details, Company Code details and Controlling area details for a Plant the following Function Module can be used.
ITOB_CHECK_PLANT
The above mentioned function module extracts all the details from the table T001W Plants/Branches, it also extracts details from the following fields.
T001K-BUKRS Company Code TKA01-KOKRS Controlling Area
Following are the Input Parameters
T001W-WERKS PLANT SY-BINPT Batch input, program running under batch input TKA02-GSBER Business Area SY-BINPT Batch input, program running under batch input DIALOG_MODE SY-BINPT Batch input, program running under batch input DIALOG_CURSOR DD03D-FIELDNAME Field name SY-STEPL Screens, current table line index SY-BINPT Batch input, program running under batch input SY-MSGTY Messages, message type
Find the program below.
REPORT ZEX_ITOBCHECKPLANT .
Parameter: p_werks like T001W-WERKS.
Data: wa_plant type T001W, d_bukrs like T001K-BUKRS, d_kokrs like TKA01-KOKRS.
Always use Pretty Printer and Extended Program Check before releasing the code.
Do not leave unused code in the program. Comment the code thoroughly. Align the comments and the Code. Follow the SAP Standards and SAP Best Practices guidelines. It’s a good practice to take a dump of the code on your local drive.
No comments:
Post a Comment