cancel
Showing results for 
Search instead for 
Did you mean: 

How to populate the WBS element in the PA segment of a Sales order item from a Custom field

MarioFranco
Participant
0 Kudos

Hello

We need to populate the WBS element inside the PA segment in the item of a sales order.

We have defined a custom field in the sales order item where the WBS element will be informed, and we have two questions.

1. Is its possible to fill the "WBS element" field  inside the PA segment with the value populated in the custom field ?

2. Is its possible add to the custom field a search help and validation against standard WBS elements?

Thanks in advance for your help.

Accepted Solutions (1)

Accepted Solutions (1)

Andrew
Product and Topic Expert
Product and Topic Expert
0 Kudos

Hi Mario,

For point # 1 - that can be populated manually but it can't be automatically filled by BaDI etc. as the Sales Order Item modification badi only allows for changes to extension (custom) fields - so you won't be able to automatically populate this with a custom field value as at 1902. Note that even populating it manually isn't very recommended since the WBS is normally automatically determined and so there is risk of re-determination in some follow on documents.

For point # 2 it should be possible as long as there's a released CDS view with the WBS elements you're referring to. You could take guidance from this youtube video from pascal: https://www.youtube.com/watch?v=c0z4gxS6eLA&t=174s

where he checks the Sales Order PO number to see if it exists already, and blocks the sales order from saving if it exists already. So you may be able to modify that logic and only permit saving if a match is found.

Regards,

MarioFranco
Participant
0 Kudos

Hi andrew.saunders ,

So...is it impossible to change a standard field throught of a subtitution from another field (custom or not) or something like that.

Please, can you explain your comment a little bit more?.

Thanks for your help!.

Best Regards

Andrew
Product and Topic Expert
Product and Topic Expert
0 Kudos

Hi Mario,

Yes that's right. So if you're talking about substituting value '001' from custom field YY1_Mario1 into a standard sales order field (like WBS element) by using the Custom Logic BaDI -> You can't do that on the sales order right now because it doesn't allow you to populate the value of a standard field. (You may be able to do it the opposite way around though, and copy a standard field value into a custom-field value).

Note I'm only talking about restrictions in using custom logic. If there's some other app/functionality for substitution you're looking at please provide some more detail.

MarioFranco
Participant
0 Kudos

andrew.saunders ,

According to your comment, that's not possible into a standar sales order field, is it?, but, it could be possible in a accounting document?, I mean, through of a subtitution, to fill the wbs element field (coding block) from a custom field.

Do you know that if is it possible?.

Please, let me know if you need more details about that and I try to give you ASAP.

Best Regards

Answers (1)

Answers (1)

former_member94298
Active Contributor
0 Kudos

Quick thought - have you looked at using a substitution (for example on business context 'coding block') to achieve this. I assume that if you are wanting to populate data in the PA segment, it is for use in financial reporting, so this might be the way to achieve the first requirement

MarioFranco
Participant
0 Kudos

Yes, ccsmith, we've looked a subtitution but we want to do this subtitution between chracteristics PA and with this business context doesn't allow it.

Can you explain your comment a little bite more?, please.

Thanks in advance.