SAPBR Technologies home

SAP in Brazil, explained

NFe Outbound / NFe 10.0 / NFe GRC – Part 3

This post continues part 2 and part 1.

13) NF-e: maintain version of message types

This decides which XML version is used for each message type when communicating with the authorities.

SPRO > Nota Fiscal Eletronica > Outbound > NF-e > NF-e: Maintain Version of Message Types (/XNFE/V_XMLVERNF)

If you issue outbound NF-e, maintain these entries:

SAP screen: 13) NF-e: maintain version of message types

If you also use receiver acknowledgment, maintain these 4 new events:

EventDescription
210200Confirmação da Operação
210210Ciência da Operação
210220Desconhecimento da Operação
210240Operação não Realizada

14) NF-e: define query for service status for authority

Set up the automatic check of NF-e availability at SEFAZ and the responsible contingency system. You’re required to run this check, and you can tune it to your batch planning or document volume.

SPRO > Nota Fiscal Eletronica > Outbound > NF-e > NF-e: Define Query for Service Status for Authority (/XNFE/V_TCUFNF)

Maintain one entry for each state (cUF) you issue notas fiscais from.

Enter the interval in seconds and the time zone of the business place’s state. For the contingency system, enter 43, 91 or SC:

CodeContingency system
43SVC Rio Grande do Sul
91SVC Ambiente Nacional
SCSCAN
SAP screen: 14) NF-e: define query for service status for authority
ContingencyStates (cUF)
SVC-AN (91), Sefaz Virtual de Contingência Ambiente NacionalAC, AL, AP, DF, ES, MG, PB, RJ, RO, RR, RS, SC, SE, SP, TO
SVC-RS (43), Sefaz Virtual de Contingência Rio Grande do SulAM, BA, CE, ES, GO, MA, MS, MT, PA, PE, PI, PR, RN

You can still use SCAN alongside SVC contingency (more on SVC later).

15) NF-e: maintain batch parameters

Set the parameters for collecting NF-es into batches and sending the batch request, for each state you use.

These parameters strongly affect CPU, disk and overall SAP NFE performance. Set them to your business needs and aim for batches with as many NF-es as possible within an acceptable time. Small values for Max. Collecting Time, Max. Batch Size or Max. Number of NF-es create more batches, which can cause performance problems. How you schedule the batch report job also affects batch creation.

SPRO > Nota Fiscal Eletronica > Outbound > NF-e > NF-e: Maintain Batch Parameters (/XNFE/V_BATCHPAR)

Say you use these settings:

SAP screen: 15) NF-e: maintain batch parameters

What does that mean? You’re sending 1 NF per batch.

How does that affect performance?

If you issue 100 NF-es in ECC, there are 100 NF-es to sign, which means roughly 4 messages with PI per document, or 400 XMLs (signing is per document).

Now compare 1 NF per batch with the recommended 50 per batch, for the same 100 NF-es. Each batch means about 6 messages from PI to SEFAZ and 6 back from PI to GRC.

1 NF-e per batch50 NF-es per batch
Batches1002
XML messages between PI and GRC1,20024
Communications between PI and SEFAZ2004

More NF-es per batch saves CPU and database load and cuts internet traffic:

SAP screen: 15) NF-e: maintain batch parameters

16) NF-e: maintain process determination for outbound NF-es

SAP NFE offers several processes for issuing an NF-e, as designed by the Brazilian authorities. With many NF-es, sending them in batches cuts data traffic and speeds up processing. With only a few, you can send them individually without a batch. The issuing process is determined when the NF-e arrives from the feeder system, according to this customizing:

SPRO > Nota Fiscal Eletronica > Outbound > NF-e > NF-e: Maintain Process Determination for Outbound NF-es (/XNFE/V_OUTBPD)

The available processes:

  • Issue of NF-e with batch
  • Issue of NF-e without batch
  • Issue of NF-e cancellation
  • Issue of NF-e skipping
  • Send NF-e to business partner
  • Send NF-e cancellation to business partner
  • Issue of NF-e number gap skipping
  • Issue of NF-e with EPEC and batch

For details on each process, see SAP Help (where I copied the list above, because I was too lazy to explain it in my own words): NFe Outbound Processing

Looks easy so far, right? No more leaps into the abyss.

SAP screen: 16) NF-e: maintain process determination for outbound NF-es

To be continued…

Comments

2 responses to “NFe Outbound / NFe 10.0 / NFe GRC – Part 3”

  1. NFe Outbound / NFe 10.0 / NFe GRC – Part 4 | SAP BRAZIL Avatar

    […] ← NFe Outbound / NFe 10.0 / NFe GRC – Part 3 […]

    Like

  2. Nora Avatar

    This is helpful information for understanding how NFe batches work.

    Like

Leave a Reply