P. 1


|Views: 81|Likes:
Published by Sarosh
SAP Sales and Distribution tips
SAP Sales and Distribution tips

More info:

Published by: Sarosh on Dec 16, 2012
Copyright:Attribution Non-commercial


Read on Scribd mobile: iPhone, iPad and Android.
download as DOC, PDF, TXT or read online from Scribd
See more
See less





RVKRED06 - Background jobs for checking blocked credit management.

If an order is no longer outside the horizon as defined in the dynamic credit check, (i.e. it is INSIDE the horizon) it can cause existing "good" orders to block. If you run this job every night, if you have your horizon set for 1 month it can cause a lot of blocks at beginning of month. Try to use 'W' for weekly horizon status. RFDKLI10 - Customers With Missing Credit Data RFDKLI20 - Reset Credit Limit for Customers RVKRED77 - Reorganize SD credit data When updating errors occur, it enables you to reorganize the open credit, delivery and billing document values. RVKRED08 - Checking sales documents which reach the credit horizon You should runs this report periodically, usually at the start of a period. The report checks all the sales documents, which reach the dynamic credit check horizon. The period for the ‘date of the next credit check’ is proposed from the current date, with the help of the period split for open sales order values.
• • • •

V_TVTW - Define Distribution Channel V_TVTA_KKB - Assign sales area to credit control area V_T014 - FI - Define Credit Control Area T001CM - FI - Assign Permitted Credit Control Area to company code

OVXG - Set up Sales Areas e.g. Sales Organization Distribution Channel Division Distribution Channel Division FD32 - Customer Credit Management OVAK - Define credit limit check by sales document type Check Credit A - Credit limit check and warning message B - Credit limit check and error message (no sales order can be created) C - Credit limit check and delivery block (block delivery if hit credit limit) Options B and C -> used for checking open order values (when you create/change the sales order) D - Automatic credit control with open order values More control in transaction OVA8 - Automatic credit control You check for open orders and deliveries, or just open deliveries. or open order values with other options Credit group --Allows you to combine different sales document types for the credit limit check

Finance have to released the delivery block OVAD .Automatic credit control . Open items No of days open Overdue open items checks is based on the ratio of open items that are overdue by a certain number of days.Define credit group. You enter a deviation % and number of days. Max open items % The customer balance must not exceed a certain percentage. Next Review Date If a customer has a credit limit of 1000 USD. You enter the credit groups when you configure the sales document types for credit management and define the (D .eg. If a user attempts to alter the order quantity of a released sales document that was previously blocked.Define credit limit check by item category Set whether to include/exclude item category for credit limit check OVA6 . Days oldest item No of days allowed for overdue or payment terms. Use of the credit check Oldest Open Item. billing documents and open items. You can groups together different business transactions which should be dealt with in the same manner with regard to the credit check.Blocked SD Documents .VKM1 . The system only reblocks the sales document if the new order quantity is above a certain % amount.automatic credit check).Define credit limit check by delivery order whether the automatic credit check occurs at the time of delivery creation and/or goods issue OVA7 . it would be reblocked again by the system. SAP default credit groups 01 .credit group for sales order 02 . you can set it so that an order can be changed by up to 10% within 30 days of original order entry date without it going back on credit block. deliveries.credit group for delivery 03 .Double click on the line items You can have the followings credit limit check :Static Depends on the customer total value of open orders. and you would like to restrict this credit limit only to be . Tick the Check for Oldest Open Item and Set the field Days oldest item = 1. Oldest open items If you don't want to deliver to the customer at all when even only 1 invoice is overdue. Released documents are still unchecked The preset % is whatever you want to set it as when configuring your automatic credit processing.credit group for goods issue OVA8 .

Define Internal Customer Number By Sales Organization (Eg. Delivering sales org will create inter-company billing IV with reference to delivery document. 3.4436 will create customer master for 4211 company code and that number will be maintained in this relationship:-4211/231) 5. Company code/sales org B (Eg. SPRO Customization required:1.review" field in customer credit master "Status" view (FD32).available in current month (say March). Create end customer master in company code/sales org 4211/RT/11 2.4211/RT) 2. If the document day is in April then the credit limit is zero. Assign Organizational Units By Plant (Eg.SI81) to sales org/distribution channel combination of ordering company code (Eg. Maintain IV01 as inter-company Price-Active in ICAA01 Process:1. 5. Automatic posting to vendor account (Optional) 6. Create customer master for 4211 company code/sales org in 4436/RT/11 3.SI81/4211/RT/11) 4. It is imperative that both Plants A & B . Maintain pricing procedure determination for 4211/RT/A/1/RVAA01-For customer sales and billing Maintain pricing procedure determination for 4436/RT/A/1/ICAA01-For inter-company billing Master data to be maintained:1. Ordering sales org will create billing document F2 with reference to delivery for end customer. 2. Sales org 4211 will accept and punch the order in the system with sold to party as end customer code in the system. Maintain PR00 as price for end customer-Active in RVAA01 4.4436) will deliver the goods to end customer and raise an inter-company billing on 4211 with reference to delivery. Pricing procedure is RVAA01 4. You can use the "NextReview date" and "Number of days" fields and combined it with the "Last int.4211/4211). Maintain PI01 as price which has to be paid to 4436-Statistical in RVAA01 5. This can happen only after 4211 raises invoice to his end customer to whom the material has been delivered by 4436. Plant to be selected is delivering plant belonging to different company code. Assign plant of delivering company code (Eg.Display of work list for credit management (configure the display variant) Configuring Intercompany Billing How to configure Inter Company Billing by: Mamta Singh INTERCOMPANY BILLING Business case: . A company arranges direct delivery of the goods to the customer from the stocks of another company belonging to the same corporate group. With reference to this order delivery will be created from the delivering plant and post the goods issue for this delivery. Company code A orders goods through its sales organization A from Plant B belonging to Company code B. With this selection system will treat this order as inter-company sales. To put in simple terms. Create OR with sold to party as end customer.Customer orders goods to company code/Sales organization A (Eg. Maintain intercom any billing type as IV for sales document type OR 3. VOKR . 6.

CONFIGURATION SETTINGS Assign Delivery Plant of the supplying company code to Sales Org + Distribution channel of the Ordering company code in the Enterprise Structure. PARTIES INVOLVED 1) End Customer 2) Ordering Company code 3) Supplying Company Code. End customer: Customer who orders goods from the ordering company code. This enables cross company sales. It is not possible to assign either a plant or a sales organization to more than one company code. Supplying Company Code: Supplies goods from its plant to the end customer specified by the ordering company code and bill the ordering company code. PRICING: . Sales Organizations and Plants are uniquely assigned to Company codes. Hence.should have the material. This internal customer number has to be assigned to the ordering sales organization. Sales organizations and plants assigned to each other need not belong to the same company code. a plant belonging to Company code A & assigned to Sales Organization A can also be assigned to Sales Organization B of Company Code B. Ordering Company Code: Which orders goods from Plant belonging to Supplying Company code through its sales organization and bills the end customer. the material is created for both the Plants A & B + their respective storage locations. We need to create customer master in Account Group – Sold to Party and maintain minimum required financial & Sales Area data. DEFINE ORDER TYPES FOR INTERCOMPNY BILLING: Menu path: IMG/ SD/Billing/Intercompany Billing/Define Order Types for Intercompany billing Assign Organizational units by Plant: Menu Path: IMG/ SD/Billing/Intercompany Billing/Assign Organizational units by Plant. In other terms. the system automatically picks up this Internal customer number whenever there is Intercompany billing. In other words. Define Internal Customer Number By Sales Organization: Menu Path: IMG/ SD / Billing/ Intercompany Billing/ Define Internal Customer Number By Sales Organization: Creating / Showing Ordering Sales Organization as Internal Customer for Supplying Company code: Transaction Code: XD01 The ordering sales organization is represented as Internal customer of Supplying company code.

Customer modification division for Table LIPOV SE12 . of Ordering company code + End customer + Material. end customer & the Material. Additional fields in work list for VL06O .Database Table . Pricing Procedure ICAA01 has condition type IV01 that represents revenues for Supplying company code in the intercompany billing.List Outbound Delivery 4. you must insert the field in customer specific table:LIPOVZ . Condition Type VPRS in the intercompany-billing document indicates cost to the supplying company code. PI01 represented under pricing procedure RVAA01 is reference condition type for IV01 and the same is defined in the condition type IV01. It is statistical condition type & meant for information purpose only. PR00 condition type also appears in Intercompany billing document. But its corresponding condition type PI01 in the billing document to the end customer is shown as a statistical item meant for information purposes. Pricing procedure RVAA01 represents condition type PR00 & any other discounts or surcharges that are meant for end customer. To add a field in the work list. The condition type IV01 in intercompany billing document represents revenue to the Supplying Company. Condition records for PI01 are created with the following key combination: Ordering sales Org + Supplying Plant + Material Pricing Procedure ICAA01is determined at Intercompany billing processing level. We assign Pricing procedure RVAA01 to combination of Sales area (Of Ordering company code) + Customer Pricing Procedure + Document Pricing Procedure of Sales document type. We maintain PR00 condition type to represent the ordering company code’s price to the end customer. It is for information purposes only and does not have bearing on the value of the document. This pricing Procedure (RVAA01) is determined both at Sales Order level & Billing processing for the end customer. Any additional field in table LIPOVZ will be reflected in the work list.6x There are no more configuration to include a new field. We also need to maintain PI01 condition type to represent costs to Ordering company code (in other words revenue to supplying company code).g. Eg: Sales Org. Condition records for PR00 are maintained using organizational elements of Ordering company code. to insert the Batch Number in the work list Component Component Type CHARG CHARG_D . e. Due to this these two condition types represent same value. The use of two different condition types in Intercompany billing is necessary to ensure that data is transmitted correctly to the financial statement (Component CO-PA).LIPOVZ Click Display -> Change You can delete away the Component DUMMY.We need to maintain two pricing procedures RVAA01 & ICAA01. Pricing Procedure ICAA01 – Pricing Procedure for Inter company billing is assigned to the combination of: 1) Sales Area (of supplying company code) + Document pricing Procedure of Billing document type IV + Customer Pricing Procedure of the Internal customer.

allowed fields.Sales Document: Item Status Once completed. Table you can use for VL06O LIKP . KOMG. Call up the ABAP Dictionary (Transaction SE11) and create data type ZZPSTYV. . 2. When you create a condition table (Transaction V/03). Note:Because of the change in structure KOMPAZ. 4. field PSTYV was included in structure KOMP. KOMP.After this. In case the required combination field is not there. PSTYV are the other terms which we need to know about. to add Fields. Call up structure KOMPAZ in the ABAP Dictionary (Transaction SE11) in the change mode and make the following entry: Component Component type: ZZPSTYV ZZPSTYV Save. check and activate your entries. KOMK. KOMKAZ. Condition access. you can use. you have to execute program BALVBUFDEL (note 122975) to reset the ALV buffer. 'ZZ .SD Document: Delivery Header Data LIPS .Please follow steps in below sequenceTry to add the filed from the field catalog. 3. Choose PSTYV as a domain..Save. field ZZPSTYV is now known in structures KOMG and KOMP because structure KOMPAZ is included in both structures.sales document item category' and as a field label. Proceed as follows: 1. the system does not propose the field in the field catalog. KOMPAZ. Call up Transaction SPRO. you can add the field through the following process to filed catalog and create the condition table. for example. It is most common that one or other time we need to use this function while configuring multi tasking & complex Pricing Architecture. not in structure KOMG ('Allowed Fields for Condition Structures'). you should be able to see the new fields in Settings -> Layout -> Change Add a Field To New Condition Table in Pricing Add a field to a new condition table in Pricing (Condition Technique):I will explain you the process with below example. Choose 'Conditions: Allowed fields' and include ZZPSTYV as a new entry. Reason and Prerequisites: For technical reasons. field catalog. Here I'm giving a simple guide to add fields to the Pricing Field Catalogues: For example you want to use field PSTYV ('Sales document item category') that is included in structure KOMP ('Pricing Communication Item') as a key for a condition table.As a short text. check and activate the change you made. you can use the field labels of PSTYV. however.. Navigate to 'Sales and Distribution -> Basic Functions -> Pricing -> Pricing Control' and execute 'Define Condition Tables'. however.SD document: Delivery: Item data VBUP .

5. and in billing document processing you find it in Include RV60AFZZ. Consider that you can also use this note as a help if you want to use other customer-specific fields as key fields in a condition table. For more information. BAPIs are complete sets of (BAPI) function modules that model a business application. **** F5 (SINGLE STEP) ---------------Single Step means debug line by line F6 ( EXECUTE) --------------Execute the subroutine / Function Module without entering into the definition. F8 ( CONTINUE) -------------Jumps to next break/watch point if available. In order processing you find the user exit in Include MV45AFZZ. When you are familiar with web developments: RFC can be compared to HTTP and BAPIs are CGI . F7 ( RETURN) ------------After entering into the subroutine/ Function module definition . For header fields. Functions can only be called via RFC. To comeout from any point of definition. Note:Now you can use field ZZPSTYV as a key field when you create a condition table Axxx. see Transaction SPRO via the path 'Sales and Distribution -> System Modifications -> Create New Fields (Using Condition Technique) -> New Fields for Pricing' and OSS Note 21040. RFC is the protocol used to call functions in an R/3 system by a caller external to R/3 or to call programs external to R/3 from an R/3 system. What is the difference between a BAPI and an RFC? BAPI stands for Business Application Programming Interface. 6. if they are tagged as RFC functions in the SAP development workbench. It is a library of functions that are released to the public as an interface into an existing SAP system from an external system. They are then called RFC function modules. otherwise it executes the whole program and comeout of it. use structure KOMKAZ instead of structure KOMPAZ and USEREXIT_PRICING_PREPARE_TKOMK instead of USEREXIT_PRICING_PREPARE_TKOMP. Supply the new field you defined by including the following source code line in USEREXIT_PRICING_PREPARE_TKOMP: MOVE xxxx-PSTYV TO TKOMP-ZZPSTYV.

ORDER PROCESSING etc. ENDFORM. USEREXIT_SAVE_DOCUMENT_PREPARE Certain application like SD still provide this form of enhancement using userexit but this practice is no longer being followed for newer extensions instead they are using EXITs which come bundeled in enhancement packages .Sometimes a need arises when the pricing is to be based on some other criteria which is not present in the form of fields in either of the two tables.. Select the userexit according to the requirement and read the comment inserted in it and start coding . in the form routine..g. HOW TO FIND USEREXITS Userexits can be found in number of ways: 1) To find userexits in SD module . The userexits are generally collected in includes and attached to the standard program by the SAP.This structure KOMG consists of two tables KOMK for Header related fields and KOMP for item related fields. All of the userexits in SD are contained in the development class VMOD. z. In other words: A BAPI function is a function module that can be called remotely using the RFC technology.This structure is used to transfer transaction data to the pricing procedure in SD and is also known as communication structure. USEREXIT Userxits allow us to add our own functionality to SAP standard program without modifying it . Press enter and you will find all the includes which contain userexits in SD for different functions like PRICING. This problem can be solved by using USEREXITS which are provided for pricing in SD. FORM USEREXIT_.applications. These are implemented in the form of subroutines and hence are also known as FORM EXITs.. The fields which are not in either of the two tables KOMK and KOMP cannot be used in pricing . Some examples of userexits in SD(SALES & DISTRIBUTION ) are: 1)ADDING OF NEW FIELDS IN PRICING In Pricing in SD the fields on the basis of which pricing is done are derived from the FIELD CATALOG which is a structure KOMG . goto object navigator(SE80) and select development class from the list and enter VMOD in it. Once the correct userexit is found the necessary customer code is inserted in the customer include starting with the z. Neverthiless existing USEREXITS will be supported by SAP an all the newer versions of SAP.. e. All Userexits start with the word USEREXIT_.. . The problem lies in finding the correct userexit and how to find it if one exists for the purpose.

one for sales order processing which is USEREXIT_PRICING_PREPARE_TKOMP (OR) USEREXIT_PRICING_PREPARE_TKOMK Depending upon which table (KOMK or KOMP) the new fields were inserted we use either of the above two userexits.Pricing takes place both when the SALES ORDER ( Transaction VA01) is created as well as when INVOICING ( Transaction VF01) is done. Exits & Enhancements . 3)The other method of finding userexits is to find the include in case of SD/MM applications where the userexits are located . Before the coding for these userexits is done . The actual structure which is visible in these userexits and which is to be filled for that particular field is TKOMP or TKOMK.Hence SAP provides 2 userexits .this can be found in the SAP reference IMG generally in the subfolder under SYSTEM MODIFICATION.g.These userexits are found in include MV45AFZZ of the standard SAP sales order creation program SAPMV45A. to display some information before the order will be saved or for making changes to certain fields before the sales order will be saved. 2)The other method of finding userexit is to find the word USEREXIT in the associated program of the transaction for which we want to determine userexit using SE38.For this purpose includes are provided in each of them .these are provided in the include RY60AFZZ which is in the standard SAP program SAPMV45A. for this we have to fill the newely created field in the communication structure KOMG for this we fill the code in the above userexit using the MOVE statement after the data that has to be passed is taken from the database table by using the SELECT statement. Some other examples of userexits in SD are: USEREXIT_NUMBER_RANGE This userexit is used to assign a different internal document number to the sales order(VA01) when it is created depending on some criteria like a different SALES ORGANIZAION(VKORG) . To create the field in header data(KOMK) the include provided is KOMKAZ and to create the field in item data(KOMP) the include provided is KOMPAZ. In the case of userexit which will be called when invoicing is done . One possible example for the need of creating new fields can be e. Frieght to be based upon transportation zone . i. USEREXIT_SAVE_DOCUMENT_PREPARE This userexit is used to insert the ABAP code which will be called when the document (sales order VA01) is just about to be saved.This userexit is used generally for custom checks on different fields .it is necessary to create a new field in either of the two tables KOMK or KOMP .e USEREXIT_PRICING_PREPARE_TKOMP or USEREXIT_PRICING_PREPARE_TKOMK These userexits are used for passing the data from the communication structure to the pricing procedure.for this no field is available in field catalog and hence it can be created in KOMK and then above userexits can be used to fill the transportation data to it. The name of the userexits are same.

These start from the word EXIT_ followed by the program name and then followed by a three digit number. e. FUNCTION EXITS These are used to add functionality through ABAP code .g. This . No access code is required to implement any tupe of exit including function exits.There are mainly six types of EXITs in sap which have been collected in the form of enhancement packages and attached to standard code in SAP. TYPES OF EXITS 1)MENU EXITS 2)FUNCTION EXITS 3)TABLE EXITS 4)SCREEN EXITS 5)KEYWORD EXITS 6)FIELD EXITS We use SAP transactions CMOD and SMOD to manage exits. it is required to create the project by using CMOD selecting the enhancement e. EXIT_SAPMV45A_002 This exit is found in SD in enhancement V45A0002. The function exits are called from the standard SAP program in the form of ABAP statement CALL CUSTOMER-FUNCTION 'NNN' This is in contrast to USEREXITs where PERFORM statement is used to call the required userexit. In the components you will see the exit EXIT_SAPMV45A_002 . These are different from USEREXIT in the way that they are implemented in the form of FUNCTIONs while in USEREXITS we use form routines for their implementation.This function exit is located in enhancement no V45A0002 . ADDING A DEFAULT SOLD-TO-PARTY in Sales Order Creation To show a default sold-to-party in this field when the user creates a sales order (VA01) we can use a function exit . V45A0002 and selecting the component (one which fulfills our need) i. Double clicking on this exit will takes us to function builder (SE37) . To implement the FUNCTION EXITs first of all the project is created and a suitable enhancement package is selected and from its compnents the function exit to be implemented is selected and on double clicking it the exit code will appear in ABAP EDITOR(se38) where a Z include will be found and the customer code should be entered in this include. These start from the word EXIT_programname_NNN ending in a 3 digit number. These are also sometimes known as function exits . e. This exit is used for our purpose.g. Before we can choose the exit we have to create a project in CMOD after that enter V45A0002 in the enhancement field and click on the components .e the exit which will be implemented in SMOD and after coding has been done the project has to be activated.g. Before implementing an exit . An exit can be coded only once.

Double clicking on this include and it will prompt us that this include does not exists do you want to create this object .e if we move the desired customer name to this structure(E_KUNNR) it will be shown in the field as the default value when we create the sales order.select yes and the include will be created . Before the field exit can have any effect the system profile parameter ABAP/FIELDEXIT in all the application servers should be set to YES ABAP/FIELDEXIT = YES. This include will be used to write our custom code . The field exit is associated with a data element existing in ABAP dictionary and hence to the screen field using that data element. We can write our own code to change the output parameter depending upon our requirements. Now when ever the SALES ORDER will be created .activated through program RSMODPRF. The function module associated with field exit shows two parameters INPUT and OUTPUT. This function also contains a customer include ZXVVA04 . Activate the include and Activate the project.function exit has one exporting parameters and two importing parameters.In this include we can write our own code that will fill the field E_KUNNR. .created. The format of field exit is : FIELD_EXIT_dataelement_A-Z or 0-9 If a particular screen and program name is not specified than the field exit will effect all the screens containing that data element. e. Input parameter contains the data passed to the field exit when the field exit was invoked by the R/3 . E_KUNNR = 301. sold-toparty field will come up with a predefined’ customer FIELD EXITS The field exits are managed. we are interested in exporting parameter which is E_KUNNR of type KNA1-KUNNR i.g.

You're Reading a Free Preview

/*********** DO NOT ALTER ANYTHING BELOW THIS LINE ! ************/ var s_code=s.t();if(s_code)document.write(s_code)//-->