cancel
Showing results for 
Search instead for 
Did you mean: 

Error in FI accounting interface

former_member198308
Active Participant
0 Kudos

Hi SD experts.

Due to gaps in the official document numbers, every SD Invoice document must have it's cprrespondig FI Accounting Document. Sometimes happens that because of errors during the interface to FI, the FI Document is not created and the user cancels the SD Invoice generating a gap in the FI official document numbers.

Is it possible to make the system not to generate the SD Invoice Document if an error occurs during the creation of the FI Accounting Document?

Thanks and best regards

Matías

Accepted Solutions (0)

Answers (4)

Answers (4)

former_member184065
Active Contributor
0 Kudos

Dear,

Is it possible to make the system not to generate the SD Invoice Document if an error occurs during the creation of the FI Accounting Document?

What do you mean by above sentence ?

First is creation of SD invoice then only we can create / release that Invoice document accounting to FI point of view .Without generation of Invoice how can we get Accounting part in SAP ?

Due to gaps in the official document numbers, every SD Invoice document must have it's corresponding Accounting Document.

When you come to Proforma Invoice ,it doesnt have accounting part so,there is some inconsistency will be happen if use any user exit or enhancement on your requirement .

How system knows ,there is error ( what type errors ) occurs during FI accounting ? If there is no Error during FI accounting creation then what what will be happen ?

If you have any doubts please let me know .

Note : If any thing is mistake in my post please explain little bit more your requirement .

Thanks,

Naren


former_member182378
Active Contributor
0 Kudos

Narendra,

When you come to Proforma Invoice ,it doesnt have accounting part so,there is some inconsistency will be happen if use any user exit or enhancement on your requirement .

(For this enhancement) The code can be written to exclude certain billing document types (e.g. F5, F8).

In other words, for all billing documents of billing types other than F5 and F8; an accounting document is mandatory.

Side comment - OP can confirm whether the business uses proforma invoices.

ivano_raimondi
Active Contributor
0 Kudos

Hello Matias,

it is technically not possible to stop billing creation after trying to post it to FI.

When the SD invoice is saved the system takes a number from SD number range, then tries to create FI document. At this point the SD invoice must be saved in every case, otherwise the number is lost.

I would suggest you to instruct to user to never reverse SD invoices if they are not released to FI yet.

You could use the routine set in VOFA (field TVFK-GRBED_S).

About the problem causing the missing release to FI, please notice that pricing and account determination can be repeated in VF02 (if the invoice is not released to FI).

Best regards,

Ivano.

former_member182378
Active Contributor
0 Kudos

Ivano,

One question to get confirmation -

field TVFK-GRBED_S, in VOFA is used specifically when using t-code VF11 (i.e. cancelling a billing document), to have a requirement, when Billing document to Cancellation billing document?

Thank you, in advance!

ivano_raimondi
Active Contributor
0 Kudos

Hi T W,

sorry, I didn't clearly explain.

My suggestion was to unallow the cancellation of a billing document if it is not released to FI yet, in order to avoid number gaps.

The scope of routine in TVFK-GRBED_S is to check if a billing document can be reversed.

So my suggestion is to implement a routine checking VBRK-RFBSK of the billing document, and stop the reversal in case it is not released yet.

Best regards,

Ivano.

former_member182378
Active Contributor
0 Kudos

Ivano,

Many thanks for your post!

former_member186385
Active Contributor
0 Kudos

Hi,

Try with the user exit  SDVFX004 -  User exit G/L line in transfer to accounting

In standard you can't achieve it

regards,

santosh

eduardo_hinojosa
Active Contributor
0 Kudos

Hi Matias,

For solving the trouble with gaps in the counter, see SAP Note 175047 - Causes for FI document number gaps (RF_BELEG).

I hope this helps you

Regards

Eduardo

PD: I am sorry, I forgot your second question. You can control it in copy control thanks to accounting status. You have this information in field VBUK-BUCHK. I believe you need to create a customer VOFM for this requirement.

former_member198308
Active Participant
0 Kudos

Hi Eduardo

Thanks for your prompt response.

Could you please be more specific in the solution proposed in the Post Data?

I put a breakpoint in the formula assigned in Copy requirements and the field VBUK-BUCHK is always blank.

Anyway, this is an special case because the Healthcare Industry Solution is active and the invoices are created directly in SD without an Order. They are posted with an 'X' in the field VBRK-FKTYP, that means that are invoces that belong to an interface.

Thanks again

Matías

eduardo_hinojosa
Active Contributor
0 Kudos

Hi Matias,

Perhaps I was confusing, my apologies. Check in the VOFM the value for VBRK-RFBSK (Status for transfer to accounting), check the values for domain RFBSK in tcode SE11.

Copy rules works, for instance I am in IS-Retail, and always you use a type of pseudo sales order and you are using billing type FP instead F2. Am I right? If I am right, please, check the settings.

Remember if you do it, you couldn't use again VFX3.

Regards

Eduardo

former_member182378
Active Contributor
0 Kudos

Interesting posts by you and Ivano!

Thank you!

Are you suggesting to put a routine in Copy requirement, in copy control VTFA (Billing document < Order)? Which would check the value of field VBRK-RFBSK;

if this field value is C (Posting document has been created) then create a billing document

Or else do not create a billing document.

Another question, in this routine, could an error message be incorporated too?

"Billing document not created"