User Exit for Pricing Condition
Hi all,
I wanted to change the values of few fields in the communication structure KOMK and KOMP for Delivery Order when pricing is being processed.
Is there a User exit for doing the same.
Regards,
Rupesh.
hi,
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 .This structure is used to transfer transaction data to the pricing procedure in SD and is also known as communication structure.This structure KOMG consists of two tables KOMK for Header related fields and KOMP for item related fields.
The fields which are not in either of the two tables KOMK and KOMP
cannot be used in pricing .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.
This problem can be solved by using USEREXITS which are provided for pricing in SD.
Pricing takes place both when the SALES ORDER ( Transaction VA01) is created as well as when INVOICING ( Transaction VF01) is done.Hence SAP provides 2 userexits ,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.These userexits are found in include MV45AFZZ of the standard SAP sales order creation program SAPMV45A.
In the case of userexit which will be called when invoicing is done ,these
are provided in the include RY60AFZZ which is in the standard SAP
program SAPMV45A. The name of the userexits are same. i.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 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. The actual structure which is visible in these userexits and which is to be filled for that particular field is TKOMP or TKOMK.
Before the coding for these userexits is done ,it is necessary to create a new field in either of the two tables KOMK or KOMP .For this purpose
includes are provided in each of them .
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.
One possible example for the need of creating new fields can be e.g. Frieght to be based upon transportation zone ,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.
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.
3)The other method of finding userexits is to find the include in case of SD/MM applications where the userexits are located ,this can be found in the SAP reference IMG generally in the subfolder under SYSTEM MODIFICATION.
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) .
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 , to display some information before the order will be saved or for making changes to certain fields before the sales order will be saved.
Hope this helps, Do reward.
Similar Messages
-
Need Help for User Exit for Pricing
Dear ABAPers
I created a user exit for pricing where I am comparing a condition type (manually entered(ZD01)) to another condition type(YD01). If the entered value is more than the other condition type than pricing should not be updated.
RATE = 0.
IF KOMP-ZZVBTYP = 'C'.
IF KOMP-PRSFD = 'X' OR
KOMP-PRSFD = 'A'.
IF KOMV-KSCHL = 'ZD01'.
LOOP AT XKOMV WHERE KSCHL EQ 'YD01'.
KOMP-KZWI2 = ( XKOMV-KBETR / 10 ).
ENDLOOP.
RATE = KOMV-KBETR / 10.
IF ( RATE <> 0 ) AND ( RATE < KOMP-KZWI2 ).
MESSAGE W991. "Maximum Allowed Discount Has Exceeded !!!!
CLEAR KOMV-KBETR.
CLEAR KOMV-KWERT.
MODIFY SCREEN.
ENDIF.
ENDIF.
ENDIF.
ENDIF.
It is giving me the message but it is also updating the pricing. I want not to be updated. So in place of modify screen i need to reset pricing procedure.
I need a function module or a abap key word which can reset the pricing procedure.
Thanks in Advance.
regards,
MAMas per i can understand you are coding in user-exits ,.. so if you are giving that
message 'Maximum Allowed Discount Has Exceeded !!!!' type 'E'.
i think it will work. I think there is no way to stop the processing without type e.
regards
shiba dutta -
USER EXIT FOR PRICISING CONDITIONS ?????
I WANT TO KNOW USER EXIT FOR DETERMINIG PRICING CONDITION IN TCODE VI01 , I WANT TO CONTROL SOME OF THE PRICES MANUALLY ....
Hi, here are enhancements (assign to your project in CMOD and activate):
V54B0001 Shipment costing: Configure pricing
V54B0003 Shipment Costs Calculation: Determine Rate Type
V54B0004 Shipment Cost Calculation: Determine Status
V54C0001 Shipment costing: Description(s) shipement cost item(s)
V54C0002 Shipment costing: Create shipment cost sub-items
V54C0003 Shipment Costs Processing: Determine Invoicing Party
V54C0004 Shipment Costs Processing: Determine Loc. for Tax Invoice
V54D0001 Shipment Costing: Determining the Tax Countries
V54KSFRC Determining the factors for apportionment of shipment costs
V54U0001 Shipment cost processing: Check whether changes made
V54U0002 Check shipment costs for completion
V54U0003 Specification of shipment cost number
V54U0004 Formatting for update of new objects (shipment costs)
V54U0005 Updating new objects in shipment cost processing
V54U0006 Shipment Purchase Order - Header Data Supply
V54U0007 Shipment Purchase Order - Item Data Supply
Regards
Filip -
User exit for Price Conditions in VA02 (update,insert or delete conditions)
Hi folks. I would like to know if anyone of you has already worked with transaction VA02...I need a user exit, which could be capable to: Erase, Update and Insert new Price Conditions.
Scenario: The user will not enter into the Price Conditions Tab. He will only make some modifications to the document via VA02 and when he saves the document, then the user exit should update, erase or include new conditions based on some logic that the user exit will implement. does anyone know a user exit for this particular case, please !
Thanks in advance.HI,
Check this.
V60F0001 SD Billing plan (customer enhancement) diff. to billing plan
V46H0001 SD Customer functions for resource-related billing
V45W0001 SD Service Management: Forward Contract Data to Item
V45S0004 Effectivity type in sales order
V45S0003 MRP-relevance for incomplete configuration
V45S0001 Update sales document from configuration
V45P0001 SD customer function for cross-company code sales
V45L0001 SD component supplier processing (customer enhancements)
V45E0002 Data transfer in procurement elements (PRreq., assembly)
V45E0001 Update the purchase order from the sales order
V45A0004 Copy packing proposal
V45A0003 Collector for customer function modulpool MV45A
V45A0002 Predefine sold-to party in sales document
V45A0001 Determine alternative materials for product selection
SDTRM001 Reschedule schedule lines without a new ATP check
Business Add-in
BADI_SD_SCH_GETWAGFZ Scheduling Agreement: Read WAGFZ from S073
BADI_SD_V46H0001 SD Customer functions for resource-related billing
Regards
Rajendra -
User exit for pricing in Sales Order
Hi Gurus,
I have a requirement while changing Sales Order and an Inquiry.Below is the requirement.
I have a custom filed at the Sales Order Item level as VBAP-XXXXX. When the user changes this value to a value (say abc) then the NET value in the Conditions tab of the line item should become zero and also the grid of the conditions tab should be displayed as zero.
I have custom item categories for which the Pricing (TVAP-PRSFD) is blank (No pricing). For this type of Item categories I can make the NET price s ZERO by implementing some custom logic in the user exit userexit_new_pricing_vbap. Since this item category is not relavant for pricing then when I carry out new pricing the net value is set to ZERO.
But for other item categories, this field (TVAP-PRSFD) is set to X (Pricing standard). For this item categories I cant make the NET value as zero.
So Can you please let me know the possibility of implementing the above mentioned logic?
Are they any user exit to update the pricing table KOMP?
Are they any user exit to change the TVAP-PRSFD value based on my requirements?
Is there any other way of implementing this logic irrespective of item categories?Hi Vinod,
I am sending you my code please check it,
if TKOMK-SPART = 10.
if XKOMV is not INITIAL.
clear v_JEXP.
READ TABLE XKOMV with key kschl = 'JEXP'.
if sy-subrc = 0.
check XKOMV-kwert = 0.
message i003(ZT) with 'Value should not be 0 for conditioin type JEXP'.
v_JEXP = 'X'.
else.
message i003(ZT) with 'Maintain the mandatory Conditioin type JEXP'.
v_JEXP = 'X'.
endif.
if v_JEXP = 'X'.
XVBUV-MANDT = sy-mandt.
XVBUV-POSNR = '000010'.
XVBUV-TBNAM = 'VBAP'.
XVBUV-FDNAM = 'PRSOK'.
XVBUV-FEHGR = 20.
XVBUV-STATG = '06'.
XVBUV-FCODE = 'PKON'.
XVBUV-SORTF = 9999.
XVBUV-LFDNR = 0000.
XVBUV-UPDKZ = 'I'.
append XVBUV.
endif.
endif.
endif.
Please suggest something to solve this.
Thanks and Regards,
Vicky. -
User exit for pricing to calculate net sales value and tax at billing level
Hi,
Can anyone give the solution for below thing.
I have written the code for to calculate the net sale a value and tax value based on condition types YTN1 & YTN2 and with pricing procedure "ZXTNIC" under user exit "userexit_field_modification" in include program LV69AFZZ
Calculation as per below
FD:
The user exit will run on the values of the line item and the header of the pricing conditions
The user exit will subtract the current net value from the value of the conditions YTN1 & YTN2, also the Tax value will be added to the value of the conditions YTN1 & YTN2.
Need the Net value = 8,032 and not 8,882 " here 8832 value is before calculation
This value will be calculated as follows = Current Net u2013 YTN1 u2013 YTN2 = 8,882 u2013 0,773 u2013 0,077 = 8,032
Need the Tax value = 2,395 and not 1,545 " here 1545 value is before calculation.
This value will be calculated as follows = Current Tax + YTN1 + YTN2 = 1,545 + 0,773 + 0, 077 = 2,395
When i will execute the VF01 transaction there in initial screen values are not updating automatically.Once we will select item line and then clicking on " item pricing condition" icon i.e., item level , then only the values are updating both in item level and header level.
But when we will execute the VF02 and VF03 the values are updating automatically as per condition.
So please suggest me is there any exit for this requirement.
Regards,
JayaramHi,
You should implement your logic in VOFM Copying routine for billing document.
Regards
Prasenjit -
Required User Exit For Pricing
Hi Folks,
Do we have any user exit to modify the way SAP selects condition records for pricing?
Regards,
Chetan.Hi Dubey,
Please try out as per given below:
If you goto the SAP Application hierachy (SE81)you can go down into individual modules.
Select the area you are interested. (It should turn yellow).
Choose Information System button.
Select Environment->Exit Techniques>Customer Exits--->Enhancements.
You should now belooking at a selection screen with the DEV classes filled in from the Application hierachy.
If you hit Execute you will get the exits for the selected part of the hierachy!
Have a play around with SE81 / Info system it can be very usefull in finding all sorts of interesting things!
Thanks,
Rajesh -
Hi,
I have the requirement that while creating invoice the condition value should be manipulated for one condition type.
I used userexit_xkomv_bewerten_end. I am getting correct output but there is red mark for this means its not activated.
Olease do let me know whether it is corrct user exit or I need to implement some thing in the code.
Regards,
SandeepWhat does your pricing analysis log say? Why can't you use a custom pricing type (and userexit_pricing_rule) assigned to your item level copy control to control the re-pricing process?
-
User exit for pricing at billing level
Hi ,
can you pl. suggest me,which user exit i can use for below scenario.
Create a new user exit attached to pricing procedure ZXTNIC in order to exclude the conditions YTN1 & YTN2 from the calculation of the net sales value and include the value of the conditions YTN1 & YTN2 to the calculation of the Tax vale.
From pricing procedure ZXTNIC need the net value to be till line 500 only and exclude the value of the conditions YTN1 & YTN2
BACKGROUND
Inter-company invoice is not calculated correctly in terms on the net sales value. The calculation of the net sales value is correct as some conditions are included in the calculations which must be excluded.
The reason for creating the user exist is that any change in the pricing conditions class can not be used to exclude them from the net price, without totally changing the concept behind the conditions (new conditions, new access sequence in taxes, IC changes and so on).
Regards,
JayaramFirst read the BADI online documentation and then [Implement thef BAdIs in the Enhancement Builder|http://help.sap.com/saphelp_nw04s/helpdata/en/b2/873842134bad04e10000000a1550b0/frameset.htm], put some break-point to check the data sent/received in debug.
Regards,
Raymond -
User-Exit for Pricing Strategy on return order.
hi,
If we have scale pricing implemented for returns how to arrive at the
base price (Pr00) condition record value based on the (Ordered qty - Returned Qty) in this scenario which user exit we shall use??
Thanks in advance,
Regards,
B.AnandhUse transaction VOFM, Formula, scale base and condition base.
-
User exit for pricing to calcumlate net sales value and taxat billing level
Hi,
Can anyone suggest me , which user exit i can used for below scenario.
Create a new user exit attached to pricing procedure ZXTNIC in order to exclude the conditions YTN1 & YTN2 from the calculation of the net sales value and include the value of the conditions YTN1 & YTN2 to the calculation of the Tax vale.
From pricing procedure ZXTNIC need the net value to be till line 500 only and exclude the value of the conditions YTN1 & YTN2
BACKGROUND
Inter-company invoice is not calculated correctly in terms on the net sales value. The calculation of the net sales value is correct as some conditions are included in the calculations which must be excluded.
The reason for creating the user exist is that any change in the pricing conditions class can not be used to exclude them from the net price, without totally changing the concept behind the conditions (new conditions, new access sequence in taxes, IC changes and so on).
FUNCTIONAL DETAILS
The user exit will run on the values of the line item and the header of the pricing conditions
The user exit will subtract the current net value from the value of the conditions YTN1 & YTN2, also the Tax value will be added to the value of the conditions YTN1 & YTN2.
Need the Net value = 8,032 and not 8,882
This value will be calculated as follows = Current Net u2013 YTN1 u2013 YTN2 = 8,882 u2013 0,773 u2013 0,077 = 8,032
Need the Tax value = 2,395 and not 1,545
This value will be calculated as follows = Current Tax + YTN1 + YTN2 = 1,545 + 0,773 + 0, 077 = 2,395
Regards,
Jayaramsolved
-
Users autorizations for pricing condition in sales order
HI all,
Can anyone tell me if there is any posibilities to control users autorization for certain pricing condition in a sales order? For example: User A can add/edit/display K007 but user B can only display K007 for a new sales order.
Thanks in advance
GeorgeRHi
Please check this link on WIKi
http://wiki.sdn.sap.com/wiki/display/ERPLO/UserexitforRestrictingUserModifyingConditiontypeinSales+Order
regards
Prashanth -
User exit for pricing date determination
Hi Friends
I want to have a custom validation at pricing date determination at billing document creation. Please anybody can help me which exit available at VF01 for this purpose.
Regards,
RaminduHello,
Check for the below link:
http://help.sap.com/saphelp_46c/helpdata/en/18/f62c7dd435d1118b3f0060b03ca329/content.htm
Prase -
BADI/User Exit for Checking Conditions in TRM Transactions
Hi All,
I have to check some conditions before saving the transaction FTR_CREATE. So that based on that condition it will be known that whether that transaction will save or not. I found some BADIs, but those are particularly working for Money market and derivatives. For my Req, I need a BADI which will check conditions for both Money market and Securities.
Exact req is, Based on Portfolio and PaymentAmount i have to restrict the transaction. Those will found in 2 tables VTBFHA and VTBFHAPO. But many BADIs doesnt contain VTBFHAPO.
If any one working on TRM can u help me out ?>
priya tavanam wrote:
> Hi Frds,
>
> I am using the FTR_TR_GENERIC Badi. In that one method is : EVT_TRANSACTION_SAVE_CHECK. In that one parameter is PI_PROXY_TRANSACTION. I want to get the attributes of Method A_TAB_CASHFLOW . That is : A_TAB_CASHFLOW~BZBETR.
-->whats ur code to read those values , it should be
lt_cashflow[] = PI_PROXY_TRANSACTION->a_A_TAB_CASHFLOW [ ] ' .
But i am unable to access this value in BADI. how access this. Can any one help me on this. -
Are user exits in Pricing for CRM 7.0 implementable in ABAP?
Hi all,
I'm new in CRM. I'm interested in creating some user exits for pricing in CRM 7.0. I know it can be done in Java but I was wandering, since now the web AS is implemented in ABAP, if I could drop Java and use solely ABAP for user exits in pricing.
ThanksHi all, I am new to CRM....Can I not create a user-exit condition type in CRM using VOFM ? The reason is that we are comfortable in ABAP but not in Java. Kindly reply with your experience. Thanks
Maybe you are looking for
-
Error when testing BSP application in SE80
Hi Experts, When i try to test the connection in se80 and SICF, I am getting the below error, Could you please help me to fix this. (Server: Netweaver CRM, windows, MSSQL) Error when processing your request What has happened? The URL http://sap0206.s
-
How do i turn off text messages from linking to computer
When i get a text message it appears on my phone and on my computer, how do I get it to not be on my computer?
-
Shutting down the Macbook nightly?
I just purchased a macbook and the manuel says to shut it down if its not going to be used for long periods of time otherwise just put it to sleep. Well what about every night...should I shut it down or just put it to sleep and leave it plugged in ch
-
WDS and WPA with 2x Express and 1 x Extreme - barbed wire in the *** easier
Frankly I am disgusted at the near impossibility of getting this to work after 5 hours of playing, resetting and stuffing around. Apple need to pull their fingers out and realise that "we make em simple so you don't need docs" is not going to cut it
-
My cs6 won't let me download it to my second computer, i did it once then deactivated it, now i want to put it back on