2022 Aug 07 6:02 PM
We are on 7.5C/1709 on-premise
I have researched this through searches, and reading almost everything that came up from start to finish. I also checked in support to see if there might be a note.
I am trying to create a fixed price entry in our conditions - it is load based not weight or quantity based but the number of loads.
ORDER_CONDITIONS_IN - has the field I need - CONDVALUE. ORDER_CONDITIONS_INX the option is not there to update it. I remember doing this years ago - so I went back to our 4.6C system. I can easily change it there, because there is not an X table to go with the conditions. ( CALCTYPCON is not in the inx table either.) I'm about ready to give up and create an enhancement point to add it. It's going to take a bit as I am going through our code.
I am limited. I do not have the integration suite piece that is an extra cost. So of course I am creating my won interface. I have to use these BAPIs to get the data into SAP. I did get a value in the condition. However, It was in the amount and the condition value had the condvalue * order quantity.
Any ideas?


if <cond>-totvalue is not INITIAL.
ls_conditions_1-condvalue = <cond>-totvalue.
clear ls_conditions_1-cond_value.
ls_conditions_1-CALCTYPCON = 'B'.
ls_conditions_1-CURRENCY_2 = <cond>-currency.
* ls_conditions_1-CONDCNTRL = 'D'.
endif.
CALL FUNCTION 'BAPI_SALESORDER_CREATEFROMDAT2'
EXPORTING
* SALESDOCUMENTIN =
order_header_in = ls_header
order_header_inx = ls_header_x
* SENDER =
* BINARY_RELATIONSHIPTYPE =
* INT_NUMBER_ASSIGNMENT =
* BEHAVE_WHEN_ERROR =
* LOGIC_SWITCH =
* TESTRUN =
* CONVERT = ' '
IMPORTING
salesdocument = lv_vbeln
TABLES
return = lt_return
order_items_in = lt_order_items
order_items_inx = lt_order_items_x
order_partners = lt_partners
order_schedules_in = lt_schedules
order_schedules_inx = lt_schedules_x
order_conditions_in = lt_conditions
order_conditions_inx = lt_conditions_x
We are on 7.5C/1709 on-premise
I have researched this through searches, and reading almost everything that came up from start to finish. I also checked in support to see if there might be a note.
I am trying to create a fixed price entry in our conditions - it is load based not weight or quantity based but the number of loads.
ORDER_CONDITIONS_IN - has the field I need - CONDVALUE. ORDER_CONDITIONS_INX the option is not there to update it. I remember doing this years ago - so I went back to our 4.6C system. I can easily change it there, because there is not an X table to go with the conditions. ( CALCTYPCON is not in the inx table either.) I'm about ready to give up and create an enhancement point to add it. It's going to take a bit as I am going through our code.
I am limited. I do not have the integration suite piece that is an extra cost. So of course I am creating my won interface. I have to use these BAPIs to get the data into SAP. I did get a value in the condition. However, It was in the amount and the condition value had the condvalue * order quantity.
Any ideas?


if <cond>-totvalue is not INITIAL.
ls_conditions_1-condvalue = <cond>-totvalue.
clear ls_conditions_1-cond_value.
ls_conditions_1-CALCTYPCON = 'B'.
ls_conditions_1-CURRENCY_2 = <cond>-currency.
* ls_conditions_1-CONDCNTRL = 'D'.
endif.
CALL FUNCTION 'BAPI_SALESORDER_CREATEFROMDAT2'
EXPORTING
* SALESDOCUMENTIN =
order_header_in = ls_header
order_header_inx = ls_header_x
* SENDER =
* BINARY_RELATIONSHIPTYPE =
* INT_NUMBER_ASSIGNMENT =
* BEHAVE_WHEN_ERROR =
* LOGIC_SWITCH =
* TESTRUN =
* CONVERT = ' '
IMPORTING
salesdocument = lv_vbeln
TABLES
return = lt_return
order_items_in = lt_order_items
order_items_inx = lt_order_items_x
order_partners = lt_partners
order_schedules_in = lt_schedules
order_schedules_inx = lt_schedules_x
order_conditions_in = lt_conditions
order_conditions_inx = lt_conditions_x
2022 Aug 08 7:02 AM
Hi c436ae948d684935a91fce8b976e5aa7
I don't see you need to populate CALCTYPCON in this BAPI. This field is used while uploading pricing conditions.
Not in the sales order create for BAPI.
You can use the following (example)
WA_ORDER_CONDITIONS_IN-COND_TYPE = 'Z007'.
WA_ORDER_CONDITIONS_IN-COND_VALUE = '100'.
WA_ORDER_CONDITIONS_INX-COND_TYPE = 'X'.
WA_ORDER_CONDITIONS_INX-COND_VALUE = 'X'.
Regards,
Venkat
2022 Aug 08 12:47 PM
In the first screen shot is the results that I get after I run the BAPI. I want the fuel surcharge to only have a fixed value. The condition value should be 24.10. Based on how it is configured the condition amount can't be change after that.
It does effect pricing. But with that said, I have tried with and without the CALCTYPCON field. I have tried using Cond_value and CONDVALUE. They both give the same results.
If anyone has had the same requirements - you want the total to be a certain dollar amount, please let me know.

2024 Nov 13 3:57 PM
Hello:
I had the same issue, and I have read the Venkat's comment about CALCTYPCON and it works, you can see the permit values in the detailed view in the condition record in the sales order. I put it a 'B' for Fixed value. Maybe it was late but, it could help anyone else.
Thanks Venkat
| User | Count |
|---|---|
| 4 | |
| 2 | |
| 2 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |