cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Bapi or FM to create a new conditions price PB00

scottcarricknwn
Participant
0 Likes
4,141

Have a mass update program that updates info records pricing. Using CND_PRICES_DETAILS_SAVE to do this. However, i need something to create new conditions prices (PB00) when they do not exist for an existing Info Record. CND_PRICES_DETAILS_SAVE seemingly is just for update, not create.

Accepted Solutions (1)

Accepted Solutions (1)

former_member1716
Active Contributor
0 Likes

Hello Scott Carrick,

You can use the FM BAPI_PRICES_CONDITIONS for your requirement.

Please find the sample program in the below link.

Sample Code

Regards!

scottcarricknwn
Participant
0 Likes

Thank you Satish!!

Answers (1)

Answers (1)

VeselinaPeykova
Active Contributor
0 Likes

The usage of BAPI_PRICES_CONDITIONS is not recommended. As stated in SAP note 1135984 - Conditions cannot be created with BAPI_PRICES_CONDITIONS: "When you use this function module, inconsistencies may occur; you should therefore not use it!"

There is a blog about loading conditions for PIRs - Difficulties in price condition load for purchasing info records with COND_A IDoc method which seems to be a safer option. With some adjustments you could make use of this approach (in a past project we had a custom program for creating and updating conditions that worked similarly to what is described in the blog so this is indeed feasible).