cancel
Showing results for 
Search instead for 
Did you mean: 

Copy control sales order to billing and accounting document

0 Kudos

Hello experts,

The sales order is created using an interface. The sales order PO number field , Assignment fields are utilized. Now the client want to send another field to sales order and the same needs to be copied to billing and accounting document also.

Apart from the these two fields, which field can be used to keep the new filed in sales order and the same has to be copied to accounting document also

Advance thanks

Dilak

Accepted Solutions (1)

Accepted Solutions (1)

pjcools
Active Contributor

Hi Dilak

Not sure I exactly understand the requirement but you could populate additional fields in the Header -> Order Data tab. There is a field called Your Reference (VBKD-IHREZ) that comes from the Business Data table VBKD. This should be copied through to the billing document. I would question why you need to also send this through to the accounting document (as it is already on the billing document). You should be able to get access to this in reporting anyway.

Please provide more information and I can give more guidance.

Thanks

Phil Cooley

0 Kudos

Thank you Phil.

Now I'm using VBKD-IHREZ for the new reference number.

' I would question why you need to also send this through to the accounting document (as it is already on the billing document). You should be able to get access to this in reporting anyway'

Finance team suggested to copy the new reference number to accounting doc for VAT return purpose.

Best Regards,

Dilak

pjcools
Active Contributor

Ok Dilak - cool.

If you need the new reference number on the accounting document you will need to copy it through using the Billing user exits. There are a number of accounting document user exits you can find via SE80, function group = V60B. You can also find them using SE37 where function module = EXIT_SAPLV60B*. You can add to the Custoer Line, Header Line and GL Account line item.

Good Luck!

Thanks

Phil Cooley

0 Kudos

Great ! thanks for your reply.

Now we are using VBKD - IHREZ for sales order but we can't use this field for Sales Return as this field been grayed out !

Could you please help us to solve this issue ? or can you suggest any other field that copy reference data up to the billing document.

Thanks,

Dilak

VeselinaPeykova
Active Contributor

In standard for REN item category Business item is not set in VOV7.

If you want to use IHREZ on item level in the sales order - you need to use an item category for which differing business data is allowed on item level (TVAP-KDERL = 'X').

0 Kudos

Hello Vaselina,

Thanks a lot !

Now the field is active.

Thanks and Regards,

Dilak

Answers (1)

Answers (1)

0 Kudos

Hi,

I guess your new field is required to be captured at header level.

If your requirement is only to have it stored and not required to be shown in the VA0* screen then you can add that particular field in VBAK, where user exit MV45AFZZ (USEREXIT_MOVE_FIELD_TO_VBAK) can be used for updating your Z field into VBAK.

Similarly if the req is only to store that field in invoice and not req to be displayed, then the new field can be created in VBRK and using the user exit "USEREXIT_FILL_VBRK_VBRP (Module pool SAPLV60A, program RV60AFZC)" the z field from VBAK can be copied into VBRK.

With above two steps the new field will have values captured during order and invoice.

For moving that field into accounting document, I would suggest that you can use BKPF-BKTXT rather creating a new field. In order to update this field, user exit SAPLV60B - EXIT_SAPLV60B_001, has to be modified and the logic of updating BKPF-BKTXT has to be included in this user exit.


If you require your new field to be shown in all these transactions at screen level, then you have to do additional modifications in the screen exit and capture the value, in sale order I have seen that in header additional data a/b, whereas I have not seen adding the new fields in the invoice header and accounting document at screen level.