Cookbook for Field Length Extension of VBTYP (Sales ...€¦ · This cookbook describes the...

20
Cookbook for Field Length Extension of VBTYP (Sales Document Category) in S/4HANA Cookbook for Field Length Extension of VBTYP (Sales Document Category) in S/4HANA ...................... 1 Overview.............................................................................................................................................. 3 Constants ............................................................................................................................................. 3 Identify affected Objects and Source Code ......................................................................................... 4 Adaption of DDIC Elements ................................................................................................................. 5 Views: .............................................................................................................................................. 5 Data Elements ................................................................................................................................. 5 Tables and Structures ...................................................................................................................... 5 Adaption of Source Code..................................................................................................................... 6 Classes, Includes, Functions, Reports .............................................................................................. 6 Interfaces ......................................................................................................................................... 7 External Interfaces (BAPIs, RFC Function Modules, IDOCs) ................................................................ 8 BAPIs ................................................................................................................................................ 8 Released RFC Function Modules ................................................................................................... 13 IDOCs ............................................................................................................................................. 13 Appendix 1 - List of Constants and Utility Methods for VBTYP: ............................................................ 16

Transcript of Cookbook for Field Length Extension of VBTYP (Sales ...€¦ · This cookbook describes the...

Page 1: Cookbook for Field Length Extension of VBTYP (Sales ...€¦ · This cookbook describes the adaption of custom code related to the field length extension of the sales document category

Cookbook for Field Length Extension of VBTYP (Sales Document

Category) in S/4HANA

Cookbook for Field Length Extension of VBTYP (Sales Document Category) in S/4HANA ...................... 1

Overview.............................................................................................................................................. 3

Constants ............................................................................................................................................. 3

Identify affected Objects and Source Code ......................................................................................... 4

Adaption of DDIC Elements ................................................................................................................. 5

Views: .............................................................................................................................................. 5

Data Elements ................................................................................................................................. 5

Tables and Structures ...................................................................................................................... 5

Adaption of Source Code ..................................................................................................................... 6

Classes, Includes, Functions, Reports .............................................................................................. 6

Interfaces ......................................................................................................................................... 7

External Interfaces (BAPIs, RFC Function Modules, IDOCs) ................................................................ 8

BAPIs ................................................................................................................................................ 8

Released RFC Function Modules ................................................................................................... 13

IDOCs ............................................................................................................................................. 13

Appendix 1 - List of Constants and Utility Methods for VBTYP: ............................................................ 16

Page 2: Cookbook for Field Length Extension of VBTYP (Sales ...€¦ · This cookbook describes the adaption of custom code related to the field length extension of the sales document category

Document History

Version Date Change

1.0 1.1

2015-10-23 2016-12-19

Final Added list of constants and methods for VBTYP as appendix

Page 3: Cookbook for Field Length Extension of VBTYP (Sales ...€¦ · This cookbook describes the adaption of custom code related to the field length extension of the sales document category

Overview This cookbook describes the adaption of custom code related to the field length extension of the

sales document category (data element VBTYP) in S/4HANA.

The sales document category has been extended from Char1 to Char4 in S/4 HANA.

Technically, all usages of the data element VBTYP (Char1) and its derivations like VBTYP_V, VBTYP_N,

and so on, have been replaced by the new data element VBTYPL (Char4), or derivations of the new

data element, such as VBTYPL_V or VBTYPL_N.

The data element VBTYP and its derivations are deprecated, but still exist technically with the old

length Char1.

All usages of the deprecated data elements in custom code have to be adopted as described in this

cookbook.

The field length extension of the sales document category has been implemented in all of S/4HANA.

There are a few single components left that still don’t fully support VBTYP with length 4, for example,

ATP – here, VBTYP with Length = 1 is still used for reasons of compatibility with APO.

In some tables, such asVBRK, a field VBTYP_EXT with length Char4 was introduced in SAP ERP 6.0

EhP7. This additional field was used to support additional code values for the sales document

category, for example, f001, f002, f003, f004, in component ‘Commodity Management’.

In S/4HANA, this additional field has been eliminated from all tables. All code values are stored in the

original table field for VBTYP, which is now longer in SAP S/4HANA.

During the conversion to S/4HANA, the content of both fields is merged automatically into the

extended field VBTYP.

Constants The constants in the include RVVBTYP have been replaced by a constant in interface

IF_SD_DOC_CATEGORY. For combinations of VBTYP values, the constants are collected as methods

in class CL_SD_DOC_CATEGORY_UTIL.

See Appendix 1 for a detailed list containing the constants and the corresponding replacement.

Page 4: Cookbook for Field Length Extension of VBTYP (Sales ...€¦ · This cookbook describes the adaption of custom code related to the field length extension of the sales document category

Identify affected Objects and Source Code 1. Identification of the affected customer objects is carried out by the Custom Code Scan Tool.

2. For a more detailed source code analysis, the report RS_ABAP_SOURCE_SCAN may also be

appropriate.

You can search by using the names of the data elements that belong to domain ‘VBTYP’. For

example, if a data element has the name SD_DOC_TYPE, use this string as the search term.

One big advantage of the report is that you can jump directly from the results list to the

source code. If you are expecting a huge number of results, the report can be executed in the

background.

Page 5: Cookbook for Field Length Extension of VBTYP (Sales ...€¦ · This cookbook describes the adaption of custom code related to the field length extension of the sales document category

Adaption of DDIC Elements

Views:

Views don’t need to be considered because, due to the change of the underlying table

structure, the view automatically receives the correct data type.

Data Elements

Before you adapt a DDIC Element, first adapt the referenced implementations first (Classes,

Reports, Functions, Includes).

This reduces the number of syntax errors.

If a data element has the domain VBTYP with Length 1 assigned to it, reassign the data

element to the domain VBTYPL with Length 4.

Tables and Structures

Before you adapt a DDIC Element, first adapt the referenced implementations (Classes,

Reports, Functions, Includes).

This reduces the number of syntax errors.

To adapt a table or structure, change the referenced data element accordingly:

Old New

VBTYP VBTYPL

VBTYP_N VBTYPL_N

VBTYP_V VBTYPL_V

Page 6: Cookbook for Field Length Extension of VBTYP (Sales ...€¦ · This cookbook describes the adaption of custom code related to the field length extension of the sales document category

Adaption of Source Code

Classes, Includes, Functions, Reports

Check and adapt data declaration with the correct data element:

i. Old: DATA: lc_vbtyp_wa(1) TYPE c.

ii. New: DATA: lc_vbtyp_wa LIKE likp-vbtyp.

iii. Fallback: If no corresponding data element is found, make the declaration with data

element VBTYPL (DATA: lc_vbtyp_wa TYPE vbtypl.)

Check and correct all parameters:

i. Import / Export / Changing Parameters for Functions

ii. Method / Class / Interface Parameters for Objects

iii. Using / Changing Parameters for Reports and Forms

Replace literals with corresponding constants in interface IF_SD_DOC_CATEGORY:

i. Old: <ls_xlikp>-vbtyp EQ '7'

ii. New: <ls_xlikp>-vbtyp EQ IF_SD_DOC_CATEGORY=>DELIVERY_SHIPPING_NOTIF

Replace CA queries (CA = ‘contains any’) with corresponding constants in interface

IF_SD_DOC_CATEGORY;

i. Old: <ls_xlikp>-vbtyp CA '7'

ii. New: <ls_xlikp>-vbtyp EQ IF_SD_DOC_CATEGORY=>DELIVERY_SHIPPING_NOTIF

Note: Comparison with operator CA would return true if one character fits. For the

new Char4 field length, this logic is wrong, and the comparison operator must be

changed to EQ.

Replace ranges with the corresponding range in class CL_SD_DOC_CATEGORY_UTIL:

i. Old: RV45C-VBTYP = VBTYP_VERK.

PERFORM R_VBTYP_FUELLEN.

select * from tvkk where vbtyp in r_vbtyp.

ii. New: r_vbtyp = cl_sd_doc_category_util=>rg_any_sales( ). select * from tvkk where vbtyp in r_vbtyp.

Loop Example: (Include LV45LF0S)

i. Old: LOOP AT FXVBFA WHERE VBELV EQ I_VBELV AND POSNV EQ I_POSNV

AND VBTYP_N CA VBTYP_AUFT

AND VBTYP_N NA VBTYP_RETOUR

AND STUFE EQ 0.

Page 7: Cookbook for Field Length Extension of VBTYP (Sales ...€¦ · This cookbook describes the adaption of custom code related to the field length extension of the sales document category

ii. New: LOOP AT FXVBFA WHERE VBELV EQ I_VBELV AND POSNV EQ I_POSNV

AND VBTYP_N in cl_sd_doc_category_util=>rg_any_order( )

AND not VBTYP_N in cl_sd_doc_category_util=>rg_any_retour( )

AND STUFE EQ 0.

Replace queries on document types with corresponding query in

CL_SD_DOC_CATEGORY_UTIL:

i. Old: CHECK: VBAK-VBTYP CA VBTYP_VERK.

ii. New: CHECK: cl_sd_doc_category_util=>is_any_sales( iv_vbtyp

= vbak-vbtyp ).

Interfaces

Replace constants with the constants from IF_SD_DOC_CATEGORY.

Note: If the constant in an interface is redundant, it can be removed and the consumer can use the

corresponding constant in: IF_SD_DOC_CATEGORY

Page 8: Cookbook for Field Length Extension of VBTYP (Sales ...€¦ · This cookbook describes the adaption of custom code related to the field length extension of the sales document category

External Interfaces (BAPIs, RFC Function Modules, IDOCs) In new releases of SAP ERP, changes to external interfaces must be compatible with previous

releases. This compatibility approach holds true for BAPIs, released RFC function modules, and

IDOCs.

The same principle applies for the conversion to S/4HANA.

To facilitate a smooth conversion, and to support interoperability of S/4HANA with other SAP

solutions such as SAP ERP, SAP CRM, and so on, external interfaces in S/4HANA are kept compatible

with SAP ERP.

In the context of external interfaces, ‘Compatible’ means:

The data transfer in RFC calls and IDOC containers is based on binary parameter structures. Changes

or enhancements to these structures in a newer release or support package must keep the order and

length of existing fields identical.

Parameters of BAPI function modules, or of released RFC function modules that contain one or more

fields of type sales-document category, are extended (at their respective ends) with additional

_LONG fields. The original, short-length fields are kept in the structures as they are.

IDOC segments that contain one or several fields of type sales document category are extended (at

their respective ends) with additional _LONG fields. The original, short-length fields remain

unchanged.

BAPIs

Outbound – Reading data from a BAPI:

Take a look at the following BAPI as an example:

BAPI_BILLINGDOC_GETDETAIL

The export parameter BILLINGDOCUMENTDETAIL is of type BAPIVBRKOUT.

Structure BAPIVBRKOUT contains the field SD_DOC_CAT (“SD Document Category”).

In S/4HANA, the structure has been extended with field SD_DOC_CAT_LONG.

Page 9: Cookbook for Field Length Extension of VBTYP (Sales ...€¦ · This cookbook describes the adaption of custom code related to the field length extension of the sales document category

SAP ERP, status in EhP 7:

SAP S/4HANA:

If you call the BAPI from within or from outside the S/4HANA system, you need to consider the

following:

Field SD_DOC_CAT_LONG (Char4) always contains the correct value for the SD document

category.

Field SD_DOC_CAT (Char1) contains the value for the SD document category in all cases

where the code value fits into the length Char1. This ensures compatibility for all short code

values.

Page 10: Cookbook for Field Length Extension of VBTYP (Sales ...€¦ · This cookbook describes the adaption of custom code related to the field length extension of the sales document category

If the code value of the SD document category is longer than Char1, the field SD_DOC_CAT

(Char1) is empty.

This applies, for example, for the code values f001, f002, f003, and f004.

It will also apply in future releases, when additional code values will be delivered by SAP.

If you are interested in one or several concrete code values of short length (Char1), you can

still use the field SD_DOC_CAT.

If you are interested in at least one code value with a length that is bigger than Char1, or if

you want to treat all possible values generically, you have to adapt the BAPI call and use the

new field SD_DOC_CAT_LONG.

Inbound – Creating or Changing Data via BAPIs

Example: BAPI_BILLINGDOC_CREATEFROMDATA

The import parameter BILLING_DATA_IN is a table of type BAPIVBRK.

BAPIVBRK contains the field REF_DOC_CA (“Document Category of Preceding SD Document”).

In S/4HANA, the structure has been extended with field REF_DOC_CA_LONG.

SAP ERP, status in EhP7 SP 09:

S/4HANA:

Page 11: Cookbook for Field Length Extension of VBTYP (Sales ...€¦ · This cookbook describes the adaption of custom code related to the field length extension of the sales document category

If you call the BAPI from within or from outside the S/4HANA system, you have to consider the

following:

If the field REF_DOC_CA_LONG (Char4) is filled with a valid code value by the caller, it will be

carried over into the document persistency.

If the Field REF_DOC_CA_LONG (Char4) is empty and the field REF_DOC_CA (Char1) is filled

with a valid code value by the caller, the value from REF_DOC_CA will be carried over.

If fields REF_DOC_CA and REF_DOC_CA_LONG are both filled, the values must be identical. If

they are not, the BAPI returns an error message and does not process the document.

If your code passes only dedicated values with a short length (Char1), you may still use the

field REF_DOC_CA.

If you need to pass at least one code value with a length bigger than Char1, or if you want to

treat all possible values generically, you have to adapt the access and use the new field

REF_DOC_CA_LONG.

BAPI*X Structures

In most cases, a related BAPI*X structure exists for BAPI structures used in BAPIs that expose

functionality in order to change existing data. The change BAPI contains a pair of parameters, one

with the BAPI structure and a related one with the BAPI*X structure.

For each attribute field in the BAPI structure, the related BAPI*X structure contains a field with the

same name, but with data type BAPIUPDATE (Char1).

This procedure was introduced to enable the identification of cases in which a field value should be

changed to the initial field value, and to distinguish this case from the case in which a field value has

not been specified.

The value ‘X’ in a field of the BAPI*X structure indicates that the value of the corresponding field in

the parameter typed with the BAPI structure should be applied as a change.

Page 12: Cookbook for Field Length Extension of VBTYP (Sales ...€¦ · This cookbook describes the adaption of custom code related to the field length extension of the sales document category

The value SPACE in a field of the BAPI*X structure indicates that no change of the corresponding field

in the parameter typed with the BAPI structure should be applied.

This is the standard behavior of change BAPIs according to the BAPI guidelines.

Fields added to a specific structure BAPI<struc> in S/4HANA are also reflected in the related structure

BAPI<struc>X.

Example: Structure BAPISDHD1X

Structure BAPISDHD1

[There are some differences for the key fields, therefore the number of fields is different.]

The implementation of a change BAPI using parameters with structures BAPISDHD1 and BAPISDHD1X

takes the field pair REFDOC_CAT/REFDOC_CAT_LONG into account if at least one of the two fields in

the structure BAPISDHD1X is filled with ‘X’.

This way, new BAPI calls can work with the new field REFDOC_CAT_LONG in the structure

BAPISDHD1X as usual (according to the BAPI guideline).

On the other hand, existing calls that are adapted to the new field REFDOC_CAT_LONG of

BAPISDHD1 still work if the original field REFDOC_CAT in the structure BAPISDHD1X is marked with

the value ‘X’. This is slightly more robust and error tolerant for callers, because the two fields

REFDOC_CAT and REFDOC_CAT_LONG are treated as a common field pair in the implementation of

the BAPI anyway.

Remark:

BAPI structures for certain Business Objects are often reused for function modules that read data,

and for function modules that change data. Some of the structure fields that are supported and filled

in the read function are not considered in the changing function, for example, because the field value

is derived from context information.

Example: In the BAPI BAPI_CUSTOMERRETURN_CHANGE, the parameter RETURN_HEADER_IN is of

Page 13: Cookbook for Field Length Extension of VBTYP (Sales ...€¦ · This cookbook describes the adaption of custom code related to the field length extension of the sales document category

type BAPISDHD1, which contains the field SD_DOC_CAT. Because the SD document category of a

customer return is a fixed value (IF_SD_DOC_CATEGORY=>RETURNS = ‘H’), changes to the field

SD_DOC_CAT or SD_DOC_CAT_LONG are ignored.

Released RFC Function Modules

The same principle described for BAPIs is also valid for released RFC function modules.

For all released RFC function modules that contain the Sales Document category as a field of an

interface parameter, SAP has enhanced the interface structures while keeping them compatible.

The original field is kept, along with the original data type (VBTYP, Char1), and an additional _LONG

field has been added to the end of the structure.

Note that this does not apply for non-released function modules.

For non-released function modules, the adaption pattern was chosen depending on the usage of the

function module in SAP-SAP integration scenarios.

For cases in which a function module is used in integration scenarios between different SAP

solutions, a compatible enhancement has been implemented to decouple the transformation to

S/4HANA from adaptions in other SAP solutions.

If a function module is not used in such integration scenarios, it may have been adapted in a way that

makes it incompatible with SAP ERP. In this case, all usages within the ERP components of S/4HANA

have been adapted accordingly.

IDOCs

Enhancements of IDOC segments in S/4HANA have been implemented in a compatible manner,

similar to the extension of BAPIs.

The handling of the field pair in IDOCs is also very similar to the handling of a field pair in a BAPI

structure.

Example:

IDOC type SALESORDER_CREATEFROMDAT2

The IDOC type is generated from BAPI_SALESORDER_CREATEFROMDAT2.

The BAPI contains the BAPI structure BAPISDHD1.

Page 14: Cookbook for Field Length Extension of VBTYP (Sales ...€¦ · This cookbook describes the adaption of custom code related to the field length extension of the sales document category

The BAPI structure has been enhanced with the additional fields SD_DOC_CAT_LONG and

REFDOC_CAT_LONG.

In the IDOC segments, the BAPI structure is mapped to a corresponding segment structure.

The ALE container is a generic restricted character field with 1000 characters.

In case the length of the segment structure exceeds 1000 characters, additional fields are generated

into a ‘child’ segment.

In case of BAPISDHD1, this leads to:

Segment structure E1BPSDHD1 with versions

E2BPSDHD1000

E2BPSDHD1001

E2BPSDHD1002

E2BPSDHD1003:

Page 15: Cookbook for Field Length Extension of VBTYP (Sales ...€¦ · This cookbook describes the adaption of custom code related to the field length extension of the sales document category

and child segment E1BPSDHD11 with versions

E2BPSDHD11000

E2BPSDHD11001:

Page 16: Cookbook for Field Length Extension of VBTYP (Sales ...€¦ · This cookbook describes the adaption of custom code related to the field length extension of the sales document category

Appendix 1 - List of Constants and Utility Methods for VBTYP:

Constant in RVVBTYP New constant Value

vbtyp_anfr IF_SD_DOC_CATEGORY=>INQUIRY 'A'

vbtyp_ange IF_SD_DOC_CATEGORY=>QUOTATION 'B'

vbtyp_auftr IF_SD_DOC_CATEGORY=>ORDER 'C'

vbtyp_sort IF_SD_DOC_CATEGORY=>ITEM_PROPOSAL 'D'

vbtyp_lp_norm IF_SD_DOC_CATEGORY=>SCHED_AGREE 'E'

vbtyp_lp_edl IF_SD_DOC_CATEGORY=>SCHED_AGREE_EXT_SERV_AGENT 'F'

vbtyp_kont IF_SD_DOC_CATEGORY=>CONTRACT 'G'

vbtyp_reto IF_SD_DOC_CATEGORY=>RETURNS 'H'

vbtyp_kl IF_SD_DOC_CATEGORY=>ORDER_WO_CHARGE 'I'

vbtyp_lino IF_SD_DOC_CATEGORY=>DELIVERY 'J'

vbtyp_ganf IF_SD_DOC_CATEGORY=>CREDIT_MEMO_REQ 'K'

vbtyp_lanf IF_SD_DOC_CATEGORY=>DEBIT_MEMO_REQ 'L'

vbtyp_rech IF_SD_DOC_CATEGORY=>INVOICE 'M'

vbtyp_stor IF_SD_DOC_CATEGORY=>INVOICE_CANCEL 'N'

vbtyp_guts IF_SD_DOC_CATEGORY=>CREDIT_MEMO 'O'

vbtyp_last IF_SD_DOC_CATEGORY=>DEBIT_MEMO 'P'

vbtyp_lvs IF_SD_DOC_CATEGORY=>WMS_TRANS_ORDER 'Q'

IF_SD_DOC_CATEGORY=>GOODS_MOVEMENT 'R'

vbtyp_stog IF_SD_DOC_CATEGORY=>CREDIT_MEMO_CANCEL 'S'

vbtyp_lire IF_SD_DOC_CATEGORY=>RETURNS_DELIVERY_FOR_ORDER 'T'

vbtyp_prof IF_SD_DOC_CATEGORY=>PRO_FORMA_INVOICE 'U'

vbtyp_bestell IF_SD_DOC_CATEGORY=>PURCHASE_ORDER 'V'

vbtyp_pbed IF_SD_DOC_CATEGORY=>INDEPENDENT_REQTS_PLAN 'W'

Page 17: Cookbook for Field Length Extension of VBTYP (Sales ...€¦ · This cookbook describes the adaption of custom code related to the field length extension of the sales document category

vbtyp_versand IF_SD_DOC_CATEGORY=>HANDLING_UNIT 'X'

IF_SD_DOC_CATEGORY=>REBATE_AGREEMENT 'Y'

vbtyp_gruko IF_SD_DOC_CATEGORY=>MASTER_CONTRACT '0'

vbtyp_kontakt IF_SD_DOC_CATEGORY=>SALES_ACTIVITIES '1'

vbtyp_extern IF_SD_DOC_CATEGORY=>EXTERNAL_TRANSACTION '2'

IF_SD_DOC_CATEGORY=>INVOICE_LIST '3'

IF_SD_DOC_CATEGORY=>CREDIT_MEMO_LIST '4'

vbtyp_fkiv_last IF_SD_DOC_CATEGORY=>INTERCOMPANY_INVOICE '5'

vbtyp_fkiv_gut IF_SD_DOC_CATEGORY=>INTERCOMPANY_CREDIT_MEMO '6'

vbtyp_liav IF_SD_DOC_CATEGORY=>DELIVERY_SHIPPING_NOTIF '7'

vbtyp_transport IF_SD_DOC_CATEGORY=>SHIPMENT '8'

vbtyp_fracht IF_SD_DOC_CATEGORY=>SHIPMENT_COSTS 'a'

vbtyp_opportunity IF_SD_DOC_CATEGORY=>CRM_OPPORTUNITY 'b'

vbtyp_liun_bed IF_SD_DOC_CATEGORY=>UNVERIFIED_DELIVERY 'c'

IF_SD_DOC_CATEGORY=>TRADING_CONTRACT 'd'

vbtyp_aufteiler IF_SD_DOC_CATEGORY=>ALLOCATION_TABLE 'e'

vbtyp_fakt_ext <Replaced by 'f001', 'f002', 'f003', 'f004'> 'f'

vbtyp_grwe IF_SD_DOC_CATEGORY=>ROUGH_GOODS_RECEIPT_IS_RETAIL 'g'

vbtyp_wa_storno IF_SD_DOC_CATEGORY=>CANCEL_GOODS_MOVEMENT 'h'

vbtyp_we IF_SD_DOC_CATEGORY=>GOODS_RECEIPT 'i'

IF_SD_DOC_CATEGORY=>JIT_CALL 'j'

vbtyp_docu IF_SD_DOC_CATEGORY=>GOODS_MOVEMENT_DOCUMENTATION 'p'

vbtyp_bulktran IF_SD_DOC_CATEGORY=>TD_TRANSPORT_IS_OIL 'r'

vbtyp_td_loadn IF_SD_DOC_CATEGORY=>LOAD_CONF_REPOSTING_IS_OIL 's'

vbtyp_td_gainlo IF_SD_DOC_CATEGORY=>GAIN_LOSS_IS_OIL 't'

vbtyp_td_return IF_SD_DOC_CATEGORY=>REENTRY_INTO_STORAGE_IS_OIL 'u'

IF_SD_DOC_CATEGORY=>DATA_COLLATION_IS_OIL 'v'

vbtyp_td_gr IF_SD_DOC_CATEGORY=>LOAD_CONF_GOODS_RECEIPT_IS_OIL 'x'

IF_SD_DOC_CATEGORY=>AFS '$'

Page 18: Cookbook for Field Length Extension of VBTYP (Sales ...€¦ · This cookbook describes the adaption of custom code related to the field length extension of the sales document category

vbtyp_fibubeleg IF_SD_DOC_CATEGORY=>ACCOUNTING_DOCUMENT_PLUS '+'

IF_SD_DOC_CATEGORY=>ACCOUNTING_DOCUMENT_MINUS '-'

IF_SD_DOC_CATEGORY=>REVENUE_RECOGNITION '#'

IF_SD_DOC_CATEGORY=>REVENUE_CANCELLATION '~'

IF_SD_DOC_CATEGORY=>REVENUE_RECOGNITION_NEW_VIEW '§'

IF_SD_DOC_CATEGORY=>REVENUE_CANCELLATION_NEW_VIEW '!'

IF_SD_DOC_CATEGORY=>SERVICE_ORDER ':'

IF_SD_DOC_CATEGORY=>SERVICE_NOTIFICATION '.'

vbtyp_lagerbeleg IF_SD_DOC_CATEGORY=>WAREHOUSE_DOCUMENT '&'

vbtyp_kommi IF_SD_DOC_CATEGORY=>PICK_ORDER '*'

IF_SD_DOC_CATEGORY=>SHIPMENT_DOCUMENT ','

IF_SD_DOC_CATEGORY=>BILL_PERIOD_END_INV 'f001'

IF_SD_DOC_CATEGORY=>BILL_PERIOD_END_CRED_MEMO 'f002'

IF_SD_DOC_CATEGORY=>BILL_PERIOD_END_INV_IB 'f003'

IF_SD_DOC_CATEGORY=>BILL_PERIOD_END_CRED_MEM_IB 'f004'

vbtyp_reserv IF_SD_DOC_CATEGORY=>RESERV_IS_OIL 'w'

Page 19: Cookbook for Field Length Extension of VBTYP (Sales ...€¦ · This cookbook describes the adaption of custom code related to the field length extension of the sales document category

Constant in RVVBTYP New method Value Name of the Range

vbtyp_vert cl_sd_doc_category_util=>is_any_sales_or_distribution( iv_vbtyp =

ABCDEFGHIJKLMNOPSTUWX012345678rstuwx

vbtyp_verk cl_sd_doc_category_util=>is_any_Sales( iv_vbtyp = ABCDEFGHIKLW0 cl_sd_doc_category_util=>rg_any_sales

vbtyp_agan cl_sd_doc_category_util=>is_INQUIRY_or_Quotation( iv_vbtyp = AB

vbtyp_lp cl_sd_doc_category_util=>is_any_Sched_agreement( iv_vbtyp = EF

vbtyp_auft cl_sd_doc_category_util=>is_any_order( iv_vbtyp = CEFHIW cl_sd_doc_category_util=>rg_any_order

vbtyp_delv cl_sd_doc_category_util=>is_any_delivery( iv_vbtyp = JT7g cl_sd_doc_category_util=>rg_any_delivery

vbtyp_lief cl_sd_doc_category_util=>is_delivery_outgoing( iv_vbtyp = JT cl_sd_doc_category_util=>rg_delivery_outgoing

vbtyp_mmli cl_sd_doc_category_util=>is_delivery_incoming( iv_vbtyp = 7g

vbtyp_anfo cl_sd_doc_category_util=>is_credit_or_debit_memo_Req( iv_vbtyp = KL

cl_sd_doc_category_util=>rg_credit_or_debit_memo_Req

vbtyp_fakt cl_sd_doc_category_util=>is_any_invoice( iv_vbtyp = MNOPSU56, f001, f002,

f003, f004 cl_sd_doc_category_util=>rg_any_invoice

vbtyp_fakt_basedat cl_sd_doc_category_util=>is_any_invoice_basedate( iv_vbtyp = MNOPS cl_sd_doc_category_util=>rg_any_invoice_basedate

vbtyp_fakt_sto cl_sd_doc_category_util=>is_invoice_or_credit_memo_canc( iv_vbtyp = NS

cl_sd_doc_category_util=>rg_invoice_or_credit_memo_canc

vbtyp_reli cl_sd_doc_category_util=>is_any_invoice_list( iv_vbtyp = 34 cl_sd_doc_category_util=>rg_any_invoice_list

vbtyp_fkiv cl_sd_doc_category_util=>is_any_intercompany( iv_vbtyp = 56, f003, f004 cl_sd_doc_category_util=>rg_any_intercompany

vbtyp_faklas cl_sd_doc_category_util=>is_any_debit_memo( iv_vbtyp = MP5

Page 20: Cookbook for Field Length Extension of VBTYP (Sales ...€¦ · This cookbook describes the adaption of custom code related to the field length extension of the sales document category

vbtyp_fakgut cl_sd_doc_category_util=>is_any_credit_memo( iv_vbtyp = O6

vbtyp_buchhaltung cl_sd_doc_category_util=>is_any_accounting( iv_vbtyp = +-#~§!

vbtyp_revrec cl_sd_doc_category_util=>is_any_Revenue_recognition( iv_vbtyp = #~§!

vbtyp_revenue cl_sd_doc_category_util=>is_any_revenue( iv_vbtyp = #~

vbtyp_revview cl_sd_doc_category_util=>Is_any_revenue_new_VIEW( iv_vbtyp = §!

vbtyp_wa cl_sd_doc_category_util=>is_goods_movement( iv_vbtyp = Rh cl_sd_doc_category_util=>rg_goods_movement

vbtyp_retour cl_sd_doc_category_util=>is_any_retour( iv_vbtyp = HKNOT6

vbtyp_verk_bed cl_sd_doc_category_util=>is_any_Sales( iv_vbtyp = ABCDEFGHIKLW0

vbtyp_auft_bed cl_sd_doc_category_util=>is_any_order( iv_vbtyp = CEFHIW

vbtyp_lief_bed cl_sd_doc_category_util=>is_delivery_outgoing( iv_vbtyp = JT

vbtyp_fakt_neg cl_sd_doc_category_util=>is_invoice_negative( iv_vbtyp = NO46, f002, f004

vbtyp_ohne_einteilung cl_sd_doc_category_util=>is_sales_wo_schedline( iv_vbtyp = DGKL

cl_sd_doc_category_util=>is_bill_period_end( iv_vbtyp = f001, f002, f003, f004 cl_sd_doc_category_util=>rg_bill_period_end