cancel
Showing results for 
Search instead for 
Did you mean: 

BAPI_J_1B_NF_CREATEFROMDATA issue for Complementary Nota Fiscals

Former Member
0 Kudos

oi,

      Eu trabalho em um ambiente de varejo, onde Nota Fiscais não pode ser criado manualmente por meio de transações J1B1N. Criamos milhares de Fiscais de nota em um dia. Todos os fiscais são criadas através de nota fornecido pelo SAP BAPI BAPI_J_1B_NF_CREATEFROMDATA. Durante um cenário ao longo da expedição, é costume usar Complementares Nota Fiscais. Criamos NFs complementares usando o mesmo BAPI. Mas, a BAPI não define o flag "Siga-on Doc. Exists" na nota fiscal de origem. NF Writer (J1B1N) se comporta corretamente. O problema existe apenas no BAPI. Uma mensagem de OSS (733226/2014) foi levantada em relação a esta questão, mas SAP respondeu dizendo que os fiscais Complementar nota são projetados para funcionar somente através J1B1N.

Eu estou tentando descobrir através deste fórum se mais alguém tem enfrentado o mesmo cenário e como eles lidaram com isso.


Referem-se a mesma questão explicado em idéias fórum com ilustração (Enhance BAPI_J_1B_NF_CREATEFROMDATA for Complementary Nota Fiscals : View Idea)


P.S: perdoa o meu português (google tradutor)


Accepted Solutions (1)

Accepted Solutions (1)

former_member209197
Active Participant
0 Kudos

In EN below

Olá Rajamurukesh.

**PT

Verifique a nota 2112203, ela implementa suporte para o campo SUBSEQ na BAPI.


**EN

Check note 2112203, it implements the support for field SUBSEQ in the BAPI.

I'm not fully sure about language rules in this forum, but you might want to post the EN text also, below the translation 😉


abs

André

Former Member
0 Kudos

Hi Andre,

              Thank you very much. I will try it out and let you know.

Former Member
0 Kudos

Hi Andre,

                 I implemented the note. It doesn't exactly work as intended. Let me explain..

The new code added by SAP checks docref field at the line item.

"IF NOT obj_item-docref IS INITIAL"

I don't think that is correct going by SAP standard. The docref field at item level is used only for 'Return nota fiscals' and not for Complementary nota fiscals. If you look at the technical help on that field, SAP clearly provides the explanation.

"

Reference to NF

It is the document number of a previous Nota Fiscal. It is used for some kinds of Nota Fiscal (Complementar, Correction, Cancel, Returns, etc) for which is necessary to make reference to a Nota Fiscal already posted.

Input values

The information will be on the header level for Complementar, Correction or Cancel Notas Fiscais. The "Subsequent Document exists" flag will be set on the referenced Nota Fiscal.

The information  will be on the item level for Returns Notas Fiscais.

"

We are dealing with Complementary nota fiscal scenario. So, I think the new code should start something like this...

""IF NOT obj_header-docref IS INITIAL"

Disclaimer: I am not an ABAP Consultant 🙂 But this is what I feel is correct going by earlier SAP definition of that field.

- Rajamurukesh

former_member209197
Active Participant
0 Kudos

Olá Rajamurukesh.

Tendo a concordar com você.

Nesse caso por favor crie uma mensagem na SAP com os seus comentários.

Acredito que uma alteração na lógica seja necessária.

André

Former Member
0 Kudos

Hi Andre,

                 OSS message 0000019727/2015 is raised to SAP now. Will await response.

Former Member
0 Kudos

The issue was fixed by SAP through a new OSS note 2116063. I tested the note and it works fine now (as expected).

Answers (0)