Fonction SAP BAPI_HU_PI_CREATE - Create Packing Instruction

Paramètre Reférence Type Long. Valeur par déf. Facultatif Description
HEADER BAPIHUPIHEADER u 264 Packing Instructions Header

Paramètre Reférence Type Long. Description
HEADER_EXT BAPIHUPIHEADER u 264 Packing Instructions Header
PIKEY BAPIHUPIHEADER-PACKINSTRID C 20 Packing Instruction Identification Number

Paramètre Reférence Long. Facultatif Description
POSITIONS BAPIHUPIPOSITION 162 Packing Instructions Items
RETURN BAPIRET2 548 Return Parameter(s)

Functionality
You can use this method to create packing instructions. The headerstructure and item table have to be filled correctly before a validpacking instruction can be created.

Example
Create packing instruction PI1 to pack 2 items of material MAT-A onto apallet:
Header ,,PACKINSTRID = 'PI1'
,,,,CHECK_PROFILE = xx
1. Item,,ITEM_NUMBER = 000010
,,,,DETAIL_ITEMTYPE = 'P'
,,,,MATERIAL = 'PALETTE'
,,,,Target_Qty = 1,,
,,,,UNIT_QTY = 'ST'
,,,,LOAD_CARRIER_INDICATOR = 'X',,
2. Item,,ITEM_NUMBER = 000020
,,,,DETAIL_ITEMTYPE = 'M'
,,,,MATERIAL = 'MAT-A'
,,,,Target_Qty = 2,,
,,,,UNIT_QTY = 'ST'

Further information
You can find more detailed information on how to fill the parameters inthe documentation for the individual parameters.
HEADER
POSITIONS

Description
This structure returns the packing instructions header data that hasbeen created.

Description
Key for the instance that has been created. You have to use this key tobe able to process the packing instructions further.

Description
Data for the creation of the header for packing instructions.
Meaning of the fields:
PACKINSTRID: field that identifies the packing instructions. If noidentifier is used, a number from the number range that has been definedin Customizing is used.
DESCRIPTION: describes the packing instructions in more detail
EXT_DESCRIPTION: contains the description that the business partner usesfor the packing instructions. This field is purely for informativepurposes.
SIZE_FIX: if this indicator is set, you can maintain the dimensionsmanually:
HEIGHT, WIDTH, LENGTH, INNER_HEIGHT, INNER_WIDTH, INNER_LENGTH,UNIT_DIM, UNIT_DIM_ISO
VOL_FIX: if this indicator is set, you can maintain the volumesmanually:
TOTAL_VOL, LOAD_VOL, ALLOWED_VOL, VOL_UNIT, VOL_UNIT_ISO,
TARE_VOL, TARE_VOL_UNIT, TARE_VOL_UNIT_ISO,
VOL_TOLERANCE
WEIGHT_FIX: if this indicator is set, you can maintain the weightsmanually:
TOTAL_WGHT, LOAD_WGHT, ALLOWED_WGHT, ALLOWED_LOAD, MAX_UNIT_OF_WGHT,MAX_UNIT_OF_WGHT_ISO,
TARE_WGHT, UNIT_OF_WT, UNIT_OF_WT_ISO,
WEIGHT_TOLERANCE
STACK_FACTOR: defines how many handling units can be stacked on top ofeach other
PRINT_NO_SHIPLABEL: determines that no external shipping labels areprinted
CLOSED_BOX: defines whether the load carrier is closed or not
CHECK_PROFILE: specifies the check profile with which the packing statusfor HU proposals and/or handling units for these packing instructions isdetermined. In the packing status check profile, you define theappropriate packing status for the possible deviations or variances ofthe HU proposal from the packing instruction.
HU_GRP1, HU_GRP2, HU_GRP3, HU_GRP4, HU_GRP5: fields that you can defineas you wish to be able to use additional functions for handling units.

Description
Data for the creation of packing instruction items.
Meaning of the fields:
ITEM_NUMBER: unique number of an item in a packing instruction orhandling unit.
DETAIL_ITEMTYPE: specifies whether the item in the packing instructionis:

  • A material that is to be packed (fill field MATERIAL with material)

  • A packing material, into which you want to pack (fill field MATERIAL
  • with packing material)
    • A lower-level packing instruction (fill field SUB_PACKINSTRID with
    • packing instruction ID)
      MATERIAL: depending on the item category, you can maintain the followingas material:
      • For a packing instruction item (load carrier or auxiliary packaging
      • material): the material number of a packaging material
        • For a packed goods item: the material number of a material to be packed

        • SUB_PACKINSTRID: maintains the identification number of a lower-levelpacking instruction for a lower-level packing instruction item
          TARGET_QTY: specifies the quantity that a handling unit should contain(according to the packing instruction)
          • For packaging materials or packed goods items, enter the quantity to be
          • packed here.
            • For lower-level packing instruction items, enter the number of
            • lower-level HUs that are to be packed.
              MINIMUM_QTY: specifies the minimum quantity that a handling unit shouldcontain according to this packing instruction:
              • For packaging materials or packed goods items, specify a minimum
              • quantity to be packed.
                • For lower-level packing instruction items, specify the number of
                • lower-level HUs to be packed.
                  ROUNDING_QTY: You use the rounding quantity to ensure that the layer isfilled so as to prevent possible damage during transport.
                  UNIT_QTY, UNIT_QTY_ISO: unit in which the quantity is given.
                  MATERIAL_MIX_ALLOWED: if this indicator is set, several materials can bepacked for the reference material.
                  BATCH_MIX_ALLOWED: if this indicator is set, several batches can bepacked for the same material in a handling unit. If the indicator is notset, only one batch can be packed.
                  LOAD_CARRIER_INDICATOR: Defines a packaging material item as loadcarrier. The load carrier is the packaging material to which all otherHU items is assigned and in which this is then transported. There mustbe one item with this indicator for each handlung unit
                  NOT_HU_RELEVANT: Defines that the packaging material is not part of theactual handling unit.

                  Description
                  Export table:
                  The table RETURN lists all the information, warnings, and errors thatoccurred when the function module was processed.