0% found this document useful (0 votes)
129 views6 pages

100.dynamic Plant Determination Logic FSD

The document provides a functional specification for determining the plant to ship an order to based on the customer's shipping address. It will use a custom user exit to dynamically determine the plant at the line item level based on the ship-to state. The user exit will retrieve the ship-to address from the order header, lookup the state in a mapping table to get the corresponding plant, and populate it in the line item. This provides flexibility to route orders to different plants depending on the customer location.

Uploaded by

Praba Karan
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
129 views6 pages

100.dynamic Plant Determination Logic FSD

The document provides a functional specification for determining the plant to ship an order to based on the customer's shipping address. It will use a custom user exit to dynamically determine the plant at the line item level based on the ship-to state. The user exit will retrieve the ship-to address from the order header, lookup the state in a mapping table to get the corresponding plant, and populate it in the line item. This provides flexibility to route orders to different plants depending on the customer location.

Uploaded by

Praba Karan
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 6

Client Name

Functional Specification

Ship to Plant Determination

Revision: Draft
Author(s): SIVA

Confidential: Client Confidentiality notice


Table of Contents

1. Revision History ....................................................................................................................................... 1


2. Introduction ............................................................................................................................................ 1
3. Solution Overview ................................................................................................................................... 1
3.1. High Level Conceptual Design ......................................................................................................... 1
3.2. Assumptions and Dependencies ...................................................................................................... 2
3.3. Out of Scope ................................................................................................................................... 2
3.4. Risks ............................................................................................................................................... 2
3.5. Key Positive and Negative Impacts .................................................... Error! Bookmark not defined.
4. System Context/Overview – N/A .............................................................................................................. 2
4.1. System Context Diagram & Architecture – N/A .................................. Error! Bookmark not defined.
4.2. Data Flow – N/A ................................................................................ Error! Bookmark not defined.
4.3. Application Navigation – N/A .......................................................................................................... 3
5. System Features ...................................................................................................................................... 3
5.1. Invoice Output ................................................................................................................................ 3
1 of 6

1. Revision History
The table below describes the versions of this document:

Revision Date User Requirement Description


Ref No.
1.0 10/10/2014 SIVA 112111 Initial Draft for Review

2. Introduction
This specification contains functional and technical requirements for the ship to plant determination for Orders
created from the Portal.

3. Solution Overview

3.1. High Level Conceptual Design


When Orders are created from the Portal, the Ship-to location is dynamic and the address is over ridden at the
transaction level. Depending on the Ship-to State either the SFO plant ( Plant = 1000 ) or the NY plant ( Plant =
1200 ) should be determined.
2 of 6

3.2. Assumptions and Dependencies


None

3.3. Out of Scope


None

3.4. Risks
None

4. Functional Design
4.1. GAP Analysis
SAP’s standard plant determination cannot support dynamic determination of Plant at the line item level based
on the Customer’s address. So, custom logic needs to be written to support Plant determination. The user exit
that has been identified is USEREXIT_SOURCE_DETERMINATION. This user exit supports dynamic
determination of plant at the line item level.
3 of 6

4.2. Flow Logic


The plant determination is based on the ship to state. At the line item level, check the State of the ship-to. Get
the Plant mapping corresponding to the ship-to State. This mapping will be maintained in a TVAR variable –
STATE_PLANT which will contain the Plant in the high value and the State in the low value.

4.3. Application Navigation


None

5. Technical Design

5.1. Overview
The user exit USEREXIT_SOURCE_DETERMINATION would contain the following logic

*&---------------------------------------------------------------------*
*& Form USEREXIT_SOURCE_DETERMINATION
*&---------------------------------------------------------------------*
* This Userexit is used to add additional logic for finding *
* the source of the plant or the item category. *
* *
* This form is called from form VBAP_FUELLEN *
* *
*----------------------------------------------------------------------*
FORM userexit_source_determination.

* set source
* VBAP-WERKS = zzfield1.

* set item category


* VBAP-PSTYV = zzfield2.

DATA : v_adrnr LIKE kna1-adrnr,


v_vbadr LIKE vbadr.
TABLES: tvarvc, kna1 .

**------------------------------------------------------------------------- **
* Get the Ship-to's State
** ------------------------------------------------------------------------ **
4 of 6

READ TABLE xvbpa WITH KEY parvw = 'RE'.

IF sy-subrc = 0.
SELECT SINGLE * FROM kna1 WHERE kunnr = xvbpa-kunnr.
IF sy-subrc = 0.
CALL FUNCTION 'SD_ADDRESS_GET'
EXPORTING
fif_address_number = kna1-adrnr
IMPORTING
fes_address = v_vbadr.
ENDIF.
ENDIF.

**---------------------------------------------------------------------- **
* Get the mapping between the plant and the State.
** --------------------------------------------------------------------- **

DATA: v_plant LIKE tvarvc-high.

SELECT * FROM tvarvc WHERE name = 'STATE_PLANT'.


IF tvarvc-low = v_vbadr-regio.
v_plant = tvarvc-high.
ENDIF.
ENDSELECT.

**---------------------------------------------------------------------- **
* Assign the plant.
** --------------------------------------------------------------------- **

IF v_plant IS NOT INITIAL.


vbap-werks = v_plant.
ENDIF.

ENDFORM. "USEREXIT_SOURCE_DETERMINATION
*eject

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy