cancel
Showing results for 
Search instead for 
Did you mean: 

Can I retrieve the current order type in service order configuration?

Matthias_G
Explorer
0 Kudos

Hello community,

we are using variant configuration in a service order (by having a configurable service product). I need to have some object dependencies which are controlled by the order type of the service order. How can I retrieve this? I have tried defining a reference characteristic linked to CAUFVD-AUART and tied this characteristic to the type-300-class assigned to the service product.

When I enter the configuration, I see my characteristic but it's empty. I would have expected to have it filled with the current value of the environment variable CAUFVD-AUART, am I doing something wrong? Or does it just not work like this.

I thought about using a variant config function module for this, but even for that I would need to retrieve the current order type and pass it down to the function… I'm lost... does anyone have an idea how to achieve this?

Accepted Solutions (0)

Answers (3)

Answers (3)

Flavio
Active Contributor

Hi mgr2016,

could you please try to create the characteristic in reference to the VBAK table, field AUART?

It should work...

Thank you and best regards,

Flavio

Flavio
Active Contributor
0 Kudos

Hi Matthias,

reason being CAUFVD is a structure, while reference characteristics shall refer to database table field, and VBAK-AUART is.

Flavio

a__engfehr
Active Participant
0 Kudos

flavio.ciotola3 is 100% correct. I use this reference characteristic in a dependency with sales orders and quotes all the time. It will accomplish exactly what you want without the need for a function.

Matthias_G
Explorer
0 Kudos

Hi Flavio,

thanks for your answer, I just answered it but I think I did it incorrectly so you might not have been notified about it. Please see if you can find my answer and maybe you have another idea or can try it yourself. Problem is, my issue is in the CS area and not SD.

Thanks!

Matthias

Matthias_G
Explorer
0 Kudos

I am closing this thread.

What I am trying to achieve is not possible in SAP standard. Only certain tables (like VBAK) work as described, but not tables like AUFK in the CS area. The characteristics have to be filled in manually now. It's not that bad as the service order is created in background and I can fill the data by my ABAP coding. But if someone is creating a service order manually, he has to enter characteristics like order type or service plant manually by copying them from the order.

Matthias_G
Explorer
0 Kudos

Dear Flavio and Andrew,

thanks a lot for your answer. Unfortunately it's not this easy 😞

I do know it works with fields from VBAK, when using a configurable material in a Sales order. I just tried it myself a minute ago: defined a new characteristic linked to VBAK-AUART, added it to a class of type 300, assigned it to a configurable material and entered a Sales order. Voilà - as soon as I hit the configuration page, the characteristic linked to VBAK-AUART is filled out with the current sales order type. So far so good…

However, in my question I already mentioned that I am not dealing with Sales orders, thus I don't have table VBAK or any other sales document table involved. I am using a configurable Service product in a Service order. Same principle - you define a configuration profile for it and assign the class to the profile. Then, once you enter the material number in the field "Service Product" in the Service order, the configuration page comes up with the characteristics defined in the profile. In this configuration page, however, my characteristic is empty and not filled out with the current service order type.

I tried to use other table references for the characteristic instead of CAUFVD-AUART: I tried CAUFV-AUART instead (CAUFV is a database view of tables AFKO and AUFK), but did not work either. CAUFV-AUART is a view field, pointing to AUFK-AUART. So I thought I'd give a last try using reference to field AUFK-AUART, but did not work either. When I hit the configuration page, the characteristic stays empty.

To me it looks like reference characteristics cannot be used in conjunction with service orders, but maybe someone in the community has tried this before and succeeded?