enhancement of default account assignment okb9.pdf

5
SAP COMMUNITY NETWORK SDN - sdn.sap.com | BPX - bpx.sap.com | BOC - boc.sap.com | UAC - uac.sap.com © 2010 SAP AG 1 Enhancement of Default Account Assignment (OKB9) Applies to: All releases of SAP for Financial postings made from a various applications like SAP-Logistics, SAP- Financials, SAP-HCM, etc For more information, visit the Enterprise Resource Planning homepage . Summary This paper highlights an alternative approach where standard default account assignment (OKB9) based on Business area or Profit Center is not sufficient and a default account assignment based on Business area and Profit center is required Author: Ajay Maheshwari Company: IBM India Private Ltd Created on: 13 July 2010 Author Bio The author works with IBM India Private Ltd as Advisory Consultant-SAP FICO. Has over 7 years of experience into ERP systems in varied positions and is actively involved in SAP implementations and rollouts in various industries

Upload: pdvanjara

Post on 01-Jan-2016

91 views

Category:

Documents


0 download

DESCRIPTION

Enhancement of OKB9

TRANSCRIPT

Page 1: Enhancement of Default Account Assignment OKB9.pdf

SAP COMMUNITY NETWORK SDN - sdn.sap.com | BPX - bpx.sap.com | BOC - boc.sap.com | UAC - uac.sap.com

© 2010 SAP AG 1

Enhancement of Default Account

Assignment (OKB9)

Applies to:

All releases of SAP for Financial postings made from a various applications like SAP-Logistics, SAP-Financials, SAP-HCM, etc

For more information, visit the Enterprise Resource Planning homepage.

Summary

This paper highlights an alternative approach where standard default account assignment (OKB9) based on Business area or Profit Center is not sufficient and a default account assignment based on Business area and Profit center is required

Author: Ajay Maheshwari

Company: IBM India Private Ltd

Created on: 13 July 2010

Author Bio

The author works with IBM India Private Ltd as Advisory Consultant-SAP FICO. Has over 7 years of experience into ERP systems in varied positions and is actively involved in SAP implementations and rollouts in various industries

Page 2: Enhancement of Default Account Assignment OKB9.pdf

Enhancement of Default Account Assignment (OKB9)

SAP COMMUNITY NETWORK SDN - sdn.sap.com | BPX - bpx.sap.com | BOC - boc.sap.com | UAC - uac.sap.com

© 2010 SAP AG 2

Table of Contents

Standard SAP – Default Account Assignment (OKB9) ...................................................................................... 3

Challenges Faced with the Standard Option .................................................................................................. 3 Alternate Solution ......................................................................................................................................................... 3

Disclaimer and Liability Notice ............................................................................................................................ 5

Page 3: Enhancement of Default Account Assignment OKB9.pdf

Enhancement of Default Account Assignment (OKB9)

SAP COMMUNITY NETWORK SDN - sdn.sap.com | BPX - bpx.sap.com | BOC - boc.sap.com | UAC - uac.sap.com

© 2010 SAP AG 3

Standard SAP – Default Account Assignment (OKB9)

The standard SAP offers to specify a default account assignment (Cost Center/Internal Order)

Per company code

Per Business area

Per Profit Center

Per Valuation area

In cases, where a default account assignment is to be specified below the company code, then “Account Assignment Detail” field in OKB9 is used to specify a default CO object per Business area or Profit center or Valuation area

Challenges Faced with the Standard Option

In cases where the SAP enterprise structure is designed in way that there are multiple profit centers pertaining to one plant, the standard default account assignment may not cater to the business needs.

For eg: If the user wants to specify a default cost center as follows, it is not possible with in the standard design

Business Area Profit Center Default Cost Center

1000 1010 10001010

2000 2010 20002010

Alternate Solution

In such cases, a slight customization in the FI substitution (RGGBS000) can get you the desired result.

This alternate solution depends upon a Z table similar to that of OKB9 and a couple of lines code in RGGBS000 outlined as below

The Z table used in the process:

Page 4: Enhancement of Default Account Assignment OKB9.pdf

Enhancement of Default Account Assignment (OKB9)

SAP COMMUNITY NETWORK SDN - sdn.sap.com | BPX - bpx.sap.com | BOC - boc.sap.com | UAC - uac.sap.com

© 2010 SAP AG 4

*---------------------------------------------------------------------*

* Start of Insertion (RGGBS000)

* This works like OKB9 based on GSBER & PRCTR

*---------------------------------------------------------------------*

Data: wa_ZOKB9 type ZOKB9.

If COBL-BUKRS = 'XXXX'.

If COBL-KOSTL IS INITIAL.

Select Single * from ZOKB9 into wa_ZOKB9

Where BUKRS = COBL-BUKRS and KSTAR = COBL-HKONT AND GSBER = COBL-GSBER AND

PRCTR = COBL-PRCTR.

If sy-subrc = 0.

COBL-KOSTL = wa_ZOKB9-KOSTL.

ENDIF.

ENDIF.

ENDIF.

*---------------------------------------------------------------------*

* End of Insertion

* This works like OKB9 based on GSBER & PRCTR

*---------------------------------------------------------------------*

Page 5: Enhancement of Default Account Assignment OKB9.pdf

Enhancement of Default Account Assignment (OKB9)

SAP COMMUNITY NETWORK SDN - sdn.sap.com | BPX - bpx.sap.com | BOC - boc.sap.com | UAC - uac.sap.com

© 2010 SAP AG 5

Disclaimer and Liability Notice

This document may discuss sample coding or other information that does not include SAP official interfaces and therefore is not supported by SAP. Changes made based on this information are not supported and can be overwritten during an upgrade.

SAP will not be held liable for any damages caused by using or misusing the information, code or methods suggested in this document, and anyone using these methods does so at his/her own risk.

SAP offers no guarantees and assumes no responsibility or liability of any type with respect to the content of this technical article or code sample, including any liability resulting from incompatibility between the content within this document and the materials and services offered by SAP. You agree that you will not hold, or seek to hold, SAP responsible or liable with respect to the content of this document.