Sunteți pe pagina 1din 13

Functional Specification

For
BW Custom Programs
<ZSVM_CA001_LOAD_BW_CUSTHIER>
Program to Extract & Flatten all Customer
Hierarchies into Z-tables for BW

Confidential to Sony Electronics Inc.


Filename: C:\Documents and Settings\almendralm\My Documents\OMS\CA-001 Flatten Customer Sales Hierarchies.doc
Page 1 of 13
Last Revision Date:

BW <ZSVM_CA001_LOAD_BW_CUSTHIER> Detail
Author's Signature:
Your signature verifies that you are appropriately qualified to create or revise this document to meet existing Sony
Electronics Inc. requirements and adequately address its intended purpose and scope.
Name

Title

Marissa Almendral

Date
DD-MMM-YYYY
24-FEB-2004

Reviewer(s) Signature:
Your signature verifies that you are appropriately qualified to review this document and that you confirm that it is
accurate, complete, and contains the necessary degree of detail to accomplish the intended purpose.
Name

Title

Date
DD-MMM-YYYY

Approver(s) Signature:
Your signature affirms you understand the purpose and scope of this document, that qualified reviewers have
reviewed the document to ensure its accuracy, and that you understand and accept overall responsibility to execute
any commitments written in the document.
Name

Title

Date
DD-MMM-YYYY

Quality Control Signature:


Your signature attests that this document complies with applicable regulatory, corporate, departmental, and SOAR
standards.
Name

Title

Date
DD-MMM-YYYY

Confidential to Sony Electronics Inc.


Filename: C:\Documents and Settings\almendralm\My Documents\OMS\CA-001 Flatten Customer Sales Hierarchies.doc
Page 2 of 13
Last Revision Date:

Table of Contents
1.

CUSTOM PROGRAM OVERVIEW


1.1
1.2
1.3

2.

BUSINESS FUNCTIONALITY OVERVIEW


2.1
2.2
2.3
2.4
2.5
2.6
2.7

3.

BATCH / ONLINE
INITIATING TRANSACTION
MENU PATH (IF APPLICABLE)
DATA MAPPING AND CONVERSION

I/O (REPEAT FOR EACH)


4.1
4.2
4.3
4.4
4.5
4.6
4.7
4.8
4.9
4.10
4.11

5.

BUSINESS FUNCTIONALITY
EXPECTED BENEFITS
HISTORICAL DATA
SECURITY CONSIDERATIONS
BUSINESS DEPENDENCIES
ASSUMPTIONS
PICTORIAL VIEW OVERALL BUSINESS FLOW DIAGRAM

CUSTOM PROGRAM SPECIFICATIONS


3.1
3.2
3.3
3.4

4.

NAMING
DESCRIPTION
TYPE (INTERFACE/CONVERSION/USER EXIT/REPORT)

PROCESS/DATA FLOW DIAGRAM


INPUT / OUTPUT
TYPE (CUBE /ODS/ Z TABLE/FLAT FILE/REPORT)
FORMAT (FOR Z TABLE/FLAT FILE/REPORT) / NAME (FOR CUBE /ODS)
FREQUENCY AND VOLUME
BUSINESS PROCESS SPECIFICATIONS
LOGICAL DATA ELEMENTS MAPPING:
ERROR MANAGEMENT
DATA RECOVERY SPECIFICATIONS
TEST SPECIFICATIONS
DATA ARCHIVE/RETENTION SPECIFICATIONS

CHANGE LOG

Confidential to Sony Electronics Inc.


Filename: C:\Documents and Settings\almendralm\My Documents\OMS\CA-001 Flatten Customer Sales Hierarchies.doc
Page 3 of 13
Last Revision Date:

1.

Custom Program Overview

1.1

Naming
Technical Name:
Display Name:

1.2

ZSVM_CA001_LOAD_BW_CUSTHIER
Flatten Customer Sales Hierarchies into Z-tables for BW

Description
This ABAP program will read the Customer Hierarchy table KNVH and populate 7 Z-tables in R/3 to
flatten out the different Customer Sales Hierarchies namely Buying Group, Planning, Retail Outlet,
Customer Ownership, Sales Force, Contract and Reseller Hierarchies.

1.3

Type (Interface/Conversion/User Exit/Report)


Interface to update different z-tables based on the Hierarchy type

Confidential to Sony Electronics Inc.


Filename: C:\Documents and Settings\almendralm\My Documents\OMS\CA-001 Flatten Customer Sales Hierarchies.doc
Page 4 of 13
Last Revision Date:

2.

Business Functionality Overview

2.1

Business Functionality
This ABAP program will read the Customer Hierarchy table KNVH and will populate 7 different Z-tables.
to hold the flattened information for the Buying Group hierarchy, Planning Hierarchy, Retail Outlet
Hierarchy, Customer Ownership Hierarchy, Contract Hierarchy, Reseller Hierarchy and Sales Force
Hierarchy. The z-tables will then be used as data sources to bring in the flattened hierarchies into BW as
individual Info Objects and would be used in the Sales related cubes. All of these Hierarchy Info Object
would have all their attributes as Navigable attributes. All of these are Sales Area relevant, just like
0CUST_SALES.

2.2

Expected Benefits
Bringing in the flattened hierarchies into BW will give the query users the ability to drilldown directly at
any level in the hierarchy without having to start at the highest level.

2.3

Historical Data

2.4

Security Considerations

2.5

Business Dependencies

2.6

Assumptions
The Customer Sales hierarchies will be maintained in R/3.

Confidential to Sony Electronics Inc.


Filename: C:\Documents and Settings\almendralm\My Documents\OMS\CA-001 Flatten Customer Sales Hierarchies.doc
Page 5 of 13
Last Revision Date:

2.7

Pictorial View Overall business flow diagram

Confidential to Sony Electronics Inc.


Filename: C:\Documents and Settings\almendralm\My Documents\OMS\CA-001 Flatten Customer Sales Hierarchies.doc
Page 6 of 13
Last Revision Date:

3.

Custom Program Specifications


This program will read the table KNVH and write the flattened hierarchy to the appropriate z-table
depending on the Customer Hierarchy type that was selected.
Hierarchy Type
B Customer Ownership
C Sales Force Hierarchy
G Buying Group
O Retail Outlet
P Planning Hierarchy
R Reseller Hierarchy
S Contract Hierarchy

Z-table
ZSVT_BW_COH
ZSVT_BW_SFH
ZSVT_BW_BYGH
ZSVT_BW_ROH
ZSVT_BW_PLNH
ZSVT_BW_RSLH
ZSVT_BW_CRTH

Provide a selection screen for the program with checkboxes for the 7 different Hierarchy types and one
checkbox with the ALL option. This will enable the program to populate selected z-tables or all z-tables.
Note:
Planning Hierarchy is not going to the used for the time being. But we would not delete the z-table or the
code from the program. It would not be any performance issue as no data currently exists for Hierarchy
type P hence nothing would be extracted to be updated.
3.1

Batch / Online
Batch - Daily

3.2

Initiating Transaction

3.3

Menu Path (if applicable)

3.4

Data Mapping and Conversion

Confidential to Sony Electronics Inc.


Filename: C:\Documents and Settings\almendralm\My Documents\OMS\CA-001 Flatten Customer Sales Hierarchies.doc
Page 7 of 13
Last Revision Date:

4.

I/O (Repeat for Each)

4.1

Process/Data Flow Diagram

4.2

Input / Output
Input

4.3

Type (CUBE /ODS/ Z Table/Flat File/Report)


Z-table

4.4

Format (for Z Table/Flat File/Report) / Name (for CUBE /ODS)


Extract data from Standard SAP Customer Hierarchy table KNVH

Field
MANDT
HITYP
KUNNR
VKORG
VTWEG
SPART
DATAB
DATBI
HKUNNR
HVKORG
HVTWEG
HSPART
GRPNO
BOKRE
PRFRE
HZUOR

Description
Client
Customer hierarchy type
Customer
Sales Organization
Distribution Channel
Division
Start of validity period for assignment
End of validity period for the
assignment
Customer number of the higher-level
customer hierarchy
Higher-level sales organization
Higher-level distribution channel
Higher-level division
Number of the routine used for copying
ID: Customer is to receive rebates
Relevant for price determination ID
Assignment to Hierarchy

Type
CLNT
CHAR
CHAR
CHAR
CHAR
CHAR
DATS
DATS
CHAR
CHAR
CHAR
CHAR
NUMC
CHAR
CHAR
NUMC

Length
3
1
10
4
2
2
8
8
10
4
2
2
3
1
1
2

Use Function Modules:


'BAPI_CUSTOMER_GET_ROOT_LIST'
'BAPI_CUSTOMER_GET_CHILDREN'
in sequence with different Customer Hierarchy type values (selection screen values driven using a variant).
Use old program ZSBR_COH_BW only as a reference to check the use of these function modules.
Would need to create ENQUEUE and DEQUEUE entries for all these 7 z-tables for data deletion and upload, in
order to lock and unlock.

Confidential to Sony Electronics Inc.


Filename: C:\Documents and Settings\almendralm\My Documents\OMS\CA-001 Flatten Customer Sales Hierarchies.doc
Page 8 of 13
Last Revision Date:

4.5

Frequency and Volume

4.6

Business Process Specifications

4.7

Logical Data Elements Mapping:

4.8

Error Management

4.9

Data Recovery Specifications

4.10

Test Specifications

4.11

Data Archive/Retention Specifications

Confidential to Sony Electronics Inc.


Filename: C:\Documents and Settings\almendralm\My Documents\OMS\CA-001 Flatten Customer Sales Hierarchies.doc
Page 9 of 13
Last Revision Date:

5.

I/O (Repeat for Each)

5.1

Process/Data Flow Diagram

5.2

Input / Output
Output

5.3

Type (CUBE /ODS/ Z Table/Flat File/Report)


Z-tables

5.4

Format (for Z Table/Flat File/Report) / Name (for CUBE /ODS)


ZSVT_BW_SFH

Field
MANDT
VKORG
VTWEG
SPART
Z_ACT_MGR
Z_R_S_MGR
Z_SLS_GRP
Z_VP_ZONE
Z_BUS_UNIT

Sales Force Hierarchy


Description
Client
Sales Organization
Distribution Channel
Division
Account Manager
Regional Sales Manager
Sales Group
VP Zone
Business Unit

ZSVT_BW_BYGH
Field
MANDT
VKORG
VTWEG
SPART
Z_SOLDTO
Z_BUYGRP

ZSVT_BW_ROH
Field
MANDT
VKORG
VTWEG
SPART
Z_RTLOUT
Z_RETAILR

Type
CLNT
CHAR
CHAR
CHAR
CHAR
CHAR
CHAR
CHAR
CHAR

Length
3
4
2
2
10
10
10
10
2

Buying Group Hierarchy

Description
Client
Sales Organization
Distribution Channel
Division
Sold To Node (Part of Hierarchy)
Buying Group of Buying Group
Hierarchy

Type
CLNT
CHAR
CHAR
CHAR
CHAR
CHAR

Length
3
4
2
2
10

Type
CLNT
CHAR
CHAR
CHAR
CHAR
CHAR

Length
3
4
2
2
10
10

10

Retail Outlet Hierarchy


Description
Client
Sales Organization
Distribution Channel
Division
Retail Outlet of Retail Outlet Hierarchy
Retailer of Retail Outlet Hierarchy

Confidential to Sony Electronics Inc.


Filename: C:\Documents and Settings\almendralm\My Documents\OMS\CA-001 Flatten Customer Sales Hierarchies.doc
Page 10 of 13
Last Revision Date:

ZSVT_BW_PLNH
Field
MANDT
VKORG
VTWEG
SPART
Z_SOLDTO
Z_PLNGCST

Description
Client
Sales Organization
Distribution Channel
Division
Sold To Node (Part of Hierarchy)
Planning Soldto of Planning Hierarchy

ZSVT_BW_COH
Field
MANDT
VKORG
VTWEG
SPART
KUNNR
Z_SUB_DIV
Z_DVSN
Z_PAR_CO

Description
Client
Sales Organization
Distribution Channel
Division
Customer Number
Sub Division Node
Division Node
Parent Company Node

Length
3
4
2
2
10
10

Type
CLNT
CHAR
CHAR
CHAR
CHAR
CHAR
CHAR
CHAR

Length
3
4
2
2
10
10
10
10

Reseller Hierarchy (for BPSD Only)

Description
Client
Sales Organization
Distribution Channel
Division
Sold To Node (Part of Hierarchy)
Parent - Sold To Node (Part of
Hierarchy)

ZSVT_BW_CRTH
Field
MANDT
VKORG
VTWEG
SPART
Z_SOLDTO
Z_PARENT

Type
CLNT
CHAR
CHAR
CHAR
CHAR
CHAR

Customer Ownership Hierarchy (for BPSD Only)

ZSVT_BW_RSLH
Field
MANDT
VKORG
VTWEG
SPART
Z_SOLDTO
Z_PARENT

Planning Hierarchy

Type
CLNT
CHAR
CHAR
CHAR
CHAR
CHAR

Length
3
4
2
2
10
10

Contract Hierarchy (for BPSD Only)

Description
Client
Sales Organization
Distribution Channel
Division
Sold To Node (Part of Hierarchy)
Parent - Sold To Node (Part of
Hierarchy)

Type
CLNT
CHAR
CHAR
CHAR
CHAR
CHAR

Length
3
4
2
2
10
10

Confidential to Sony Electronics Inc.


Filename: C:\Documents and Settings\almendralm\My Documents\OMS\CA-001 Flatten Customer Sales Hierarchies.doc
Page 11 of 13
Last Revision Date:

5.5

Frequency and Volume

The data in these z-tables would be loaded daily (delete old data and load latest hierarchy data) using the ABAP
program. ABAP program would be variant driven for the z-tables load using the radio button option for the different
Hierarchy types already specified.
5.6

Business Process Specifications

5.7

Logical Data Elements Mapping:

5.8

Error Management

5.9

Data Recovery Specifications

5.10

Test Specifications

5.11

Data Archive/Retention Specifications

Confidential to Sony Electronics Inc.


Filename: C:\Documents and Settings\almendralm\My Documents\OMS\CA-001 Flatten Customer Sales Hierarchies.doc
Page 12 of 13
Last Revision Date:

6.

Change Log

Document Title:

CA-001 Flatten Customer Sales Hierarchies

Author:

Marissa Almendral

Date Created:

Feb 24, 2004

Name

Date of
Changes

Summary of Changes

Jas Uberoi

4/5/2004

Jas Uberoi

10/19/2005

Changes to the Z-tables and Fields with reference to


Old Program and the Function Modules to be used.
Updated the Prog tech name and added comments
Document reviewed

***End of Document***

Confidential to Sony Electronics Inc.


Filename: C:\Documents and Settings\almendralm\My Documents\OMS\CA-001 Flatten Customer Sales Hierarchies.doc
Page 13 of 13
Last Revision Date:

S-ar putea să vă placă și