[NFe] Integração com Mensageria via arquivo txt

Pessoal, bom dia!
Estamos configurando um projeto de NFe onde o SAP irá trocar informações com uma mensageria NonSAP via arquivo txt e estamos com dificuldade de identificar onde e como fazer com que a J_1B_NFE_XML_OUT fará a conversão dos dados de Envio, Cancelamento e Inutilização para arquivo txt e salvar num diretório que a mensageria irá ler.
A mesma dúvida ocorre para o processo de retorno do processamento do Envio, Cancelamento e Inutilização, pois a mensageria irá salvar os retornos em arquivo txt e teremos um JOB no SAP que ficará lendo esses arquivos para atualizar o status no SAP e pelo que andei lendo teremos de executar a J_1B_NFE_XML_IN_TAB.
Tanto a J_1B_NFE_XML_OUT quanto a J_1B_NFE_XML_IN_TAB funcionam para enviar, cancelar e inutilizar notas fiscais?
No aguardo, obrigado por qualquer ajuda.
Danilo

Bom dia Danilo,
Existem basicamente três formas para você gerar um arquivo texto pra saída, e vai depender de para onde você quer levar os dados e que ferramentas tem disponível:
- importar a função J_1B_NFE_XML_OUT no PI e fazer um adapter to file
- criar um programa que possa ser configurado na SM59 para destino e nele travar as informações e gravar o arquivo
- fazer um ABAP enhancement na própria função J_1B_NFE_XML_OUT (ela eh interface apenas, não tem código) para gravar o arquivo
A função J_1B_NFE_XML_OUT é usada nos 4 pedidos possíveis à mensageria não standard:
- envio
- cancelamento
- inutilização de nota existente
- inutilização de nota por gap
A função J_1B_NFE_XML_IN_TAB é a porta de entrada dos retornos dos processamentos acima.
Atenciosamente, Fernando Da Ró

Similar Messages

  • Unir varios arquivo .txt em somente um arquivo .txt

    Ola Pessol
    Por gentileza
    meu programa gera a cada 1hora, uma arquivo .TXT, durante dias de mediçoes.
    gostaria de saber se é possivel unir todos esses arquivos .txt em um arquivo só?
    se for possivel como posso faze-lo
    obrigado

    Olá Gklaus, bom dia.
    Primeiramente obrigado pela atenção. Entao sobre meu problema ele foi parcialmente resolvido. Pois nao tenho experiencia com o labview.
    Bom, preciso coletar uma forma de onda de um capacitor durante varios dias seguidos sem intervalos. ( 4 canais, 4 capacitores diferentes, 4 formas de onda). Precisaria que o programa que tenho, coletasse a cada segundo  mais de uma amostra por canal (ou seja, mais de um ponto na curva de subida do capacitor por segundo e por canal).
    Minha ideia era ligar o circuito e coletar os dados , porem quando faço isso atualmente o tempo da mediçao sai fora de sincronismo e o mesmo fica lento, depois de sete horas.
    No final usaria esse arquivo (.txt) para plotar um grafico em um software expecifico Kaleidagraph. Estou trabalhando com o USB 6009 utilizando 4 canais modo diferentical, não sei como poderia adaptar meu programa para TDMS, e se fosse possivel conseguiriar converte-lo para txt?
    Obs: o programa atual esta dividindo o arquivo .txt a cada 1000 segundos, achei q isso fosse resolver meu problema mas não resolveu
    Abaixo segue o programa
    Muito Obrigado
    Anexos:
    VI.zip ‏132 KB

  • NFe de entrada com XML versão 1.10 em ambiente com versão de XML 2.00

    Olá colegas,
    Nossos locais de negócio estão configurados para a NFe na versão XML 2.0.
    Com isso, todas notas criadas, tanto de saída quanto de entrada são da versão 2.00 do XML.
    Entretanto, ainda recebemos notas de clientes na versão do XML 1.10.
    Com isso, em processos de devolução em SD, ao informar os campos que compõe a chave da NFe, temos dificuldade com campo tpEmis. Consequentemente, não conseguimos gerar a chave corretamente.
    Este campo não existe na versão 1.10 do xml, pois integrava o campo do nr.aleatorio.
    Pergunto: Como está sendo resolvida esta questão por quem já se deparou com ela?
    Obrigado.
    Heron Caetano

    Heron,
    no recebimento, vc pode ir no botao Nota Fiscal, aba NFe, e setar a versao para "1,10".
    Isso vai fazer com que os parametros sejam mostrados como no layout 1.10 (i.e. randomico de 9 digitos e sem tpEmis).
    Veja a nota [1470661|https://service.sap.com/sap/support/notes/1470661].
    Abs,
    Henrique.

  • Error while calling COM routines via application prog(return code 1028533-)

    Hello Expert,
    In Interactive Demand Planning ( /SAPAPO/SDP94 ), when I'm trying to load data in a planning book , error
    'Error while calling COM routines via application program (return code 1028533-)' is encountered.
    In my selection id, i have only two locations....there is no material selection. 
    When I select the 1st location and load the data its getting loaded properly.....but when i select the 2nd location and try loading data ...the above error is coming.
    I did run /SAPAPO/TS_LCM_CONS_CHECK but the problem persist.
    Any advise to fix this issue would be much appreciated.
    Thanks.
    Tom

    Hi Tom,
    Please see if below exiting threads help you.
    COM error 40134 in Interactive Planning on SCM 5.0 Support Pack SAPKY50011
    Error for COM Routine application program (return code 40028)
    Thukral

  • I want to update to iOS 7 when it comes out via iTunes. I gather that I will require iTunes 11.1 to do so, but I recently updated my version (today) to version 11.0.5. Will I be OK or wait until I have a Wi-Fi connection and do it then?

    I want to update to iOS 7 when it comes out via iTunes. I gather that I will require iTunes 11.1 to do so, but I recently updated my version (today) to version 11.0.5. Will I be OK or wait until I have a Wi-Fi connection and do it then?

    More than likely, the new version of itunes will be released later today in conjunction with iOS 7. But, yes, you can update the phone via WiFi. Make sure to set up icloud and do a back up first.

  • How come the item value does not come thru via PL/SQL anonymous block?

    Hi,
    It's a Form with 3 tables -
    1) ClinicianProfileTb (with about 40 columns, insert/update via DML),
    2) PeopleTb (with about 7 columns, insert/update via PL/SQL anonymous block) and
    3) ClinicianPracticeTb (with about 10 columns, insert/update via PL/SQL anonymous block) for after-submit-processes.
    So I have several After-Submit-Processes. For some reason, it appears that PeopleId which is supposed to come thru via the 2nd After-Submit-Process (ie: Insert/Update PeopleTb) does not do the way it's supposed to. And when I press "Create" button at the bottom, I got the following error msg:
    ORA-01400: cannot insert NULL into ("TEST_0712"."CLINICIANPRACTICETB"."PEOPLEID")
    I tried the "debug" mode (via edit page link), but to no avail. (I'm newbie, trying to learn and deliver at the same time :)).
    I uploaded the app to apex.oracle.com, if someone could kindly take a look and let me know what goes wrong, it'd be greatly appreciated.
    workspace: test_0712
    app: 43408 - TEST
    user: demo
    pswd: demoPswd
    Page#21 -> look at the After-Submit-Processes -> in "Insert/Update PeopleTb" it appears that PeopeId does not come thru; thus it cannot be updated to ClinicianProfileTb.PeopleId (allows null) -> and thus cannot be inserted into ClincianPracticeTb.PeopleId (which does NOT allow null). Basically my logic is that in order to create ANY row in ClinicianPracticeTb, BOTH PracticeId AND PeopleId must be present.
    Acutally I should have used the PeopeTb as DML (as the driving table) to enforce that PeopleId must be present in order to insert ClinicianProfileTb and ClinicianPracticeTb, but it'd be lots of codes to write to insert/update in ClinicianProfileTb (40 columns).
    In addition, does ApEx consider EVERY SINGLE after-submit-process are in ONE transaction for commit/rollback? It appears that it treats all PL/SQL anonymous blocks are in ONE transaction, while Automatic Row Processing (DML) is commited/rolled back on its own?
    Thanks much,
    Helen

    All blocks that do not commit in one of the ways I detailed (and which do not explicitly commit using a commit statement) are part of the transaction started with > the first DML statement issued in any of the page processes and continuing until a commit is issued.Say, there are the following processes in the After-Submit-Processes:
    1. Process1 -> Automatic Row Processing (DML)
    2. Process2 -> PL/SQL anonymous block
    3. Process3 -> PL/SQL anonymous block
    Based on what you describe, in the event that if there is no explicit "commit" issued in any of these processes, then an implicit "commit" will be issued at the end of Process3?
    Thanks, Scott.
    Doreen

  • Call MS com object via SOAP from WLS 6.1

    I generated a WSDL file for a Microsoft com object and can easily write a WL
    web service that calls it using Workshop 7.0. But I need to deploy it on a
    WLS 6.1 server. (I was hoping that Workshop would simply generate the source
    code required for accessing the com object via soap, which I could then cut
    and paste into my own source, but it doesn't do that.)
    Does anyone have an example of how to do this?

    Hi Mel,
    You said that you want to "deploy it on WLS 6.1", but I think what you really
    meant is that you want a J2EE component (i.e. JSP, Servlet, EJB, etc.) running
    in WLS 6.1 to consume the WSDL you created from the COM object, right?
    If so, the web services package in WLS 6.1 can be used to do this :-) If you tell
    me what type of J2EE component (i.e. JSP, Servlet, EJB, etc.) you want to be the
    client, I'll provide you with some sample code. Also, be sure you attach the WSDL
    that was generated, because WLS 6.1's WSDL processor isn't as complete as the
    one in WLS 7.0 and Workshop :-)
    Regards,
    Mike Wooten
    "Mel Werbow" <[email protected]> wrote:
    I generated a WSDL file for a Microsoft com object and can easily write
    a WL
    web service that calls it using Workshop 7.0. But I need to deploy it
    on a
    WLS 6.1 server. (I was hoping that Workshop would simply generate the
    source
    code required for accessing the com object via soap, which I could then
    cut
    and paste into my own source, but it doesn't do that.)
    Does anyone have an example of how to do this?

  • Error while calling COM routines via application program (return code 40028

    Hi ,
    When i am doing these steps i am getting the following error.
    1.from SAP menu...Demand Planning>Planning>Interactive Demand planning
           2.after the transaction gets loaded...click on the 2nd button that is selection window from the left ALV menu..on the top.
            3.type the below
    show -  Material
    APO Planning Version - K01
    Material  - 12345
    4.Material 12345 will be loaded
    5.Double click and i am getting  ''error Error while calling COM routines via application program (return code 40028)''
    Note : Observed that this is not happening everytime, but happening alternatively.
    Can any one say what is the problem for Error.
    Thanks
    Gerard

    Hello Gerard, Hello Krishna,
    -> The liveCache application failed with COM error::
                                   40028 Illegal timestamp in rough timegrid
    More details about COM error 40028 you will see in TA /n/sapapo/om10
         -> Return code: 40028 -> execute ::
    Invalid time stamp in the time buckets profile relation     
    ( om_ts_tgrelinvalidstamp )     
       < click on '?' mark >
    -> Open an OSS message in accordance with SAP note 167280 if further help
         needed to solve the issue on your system.
    Thank you and best regards, Natalia Khlopina

  • Inutilização de uma nfe com mensageria não sap

    Prezados Colegas,
    Gostaria de solicitar uma preciosa ajuda de vocês.
    Estou em um projeto de implementação, utilizando a solução SAP para NF-e, porém com uma mensageria NÃO-SAP que o cliente já utiliza hoje.
    Preciso entender como funciona o seguinte cenário:
    Foi emitida uma NF-e no ERP SAP e enviada para a Mensageria. Por algum problema na SEFAZ não houve uma resposta para a mensageria e neste intervalo o faturista vê que tinha erro na NF-e e resolve cancelar a nota.
    No monitor de NF-e a nota está com estes parâmetros:
    Status Ação : engrenagem
    Etapa do Processo: em processamento
    Status do Documento: Aguardar resposta
    Status de Com. Sistema: Enviado ao Sistema de Envio de mensagens
    Como devo proceder para cancelar esta nota e solicitar inutilização na SEFAZ ? A NF-e tem uma chave de acesso, a Inutilização vai gerar uma outra chave correto?, e na volta está chave  (da inutilização) ficará gravada na tabela, e no Livro de Saídas aparecerá como inutilizada ?
    Confirmem se são estes os passos que tenho que seguir:
    No monitor, seleciono a nota e faço um ESTORNO ANTES DA AUTORIZAÇÃO;  em seguida ESTORNAR DOCUMENTO DE ORIGEM, e depois eu clico em ENVIAR (ESTA É A SOLICITAÇÃO DE INUTILIZAÇÃO ?)
    E pelo fato de ser outra mensageria, tem alguma implicação diferente, algo que eventualmente não funcione na atualização do SAP ?
    Antecipadamente agradeço,
    Diógenes

    Fernando,
    Eu vou reformular minha questão, porque acredito que misturei o cenário que o cliente comentou que existe hoje e como isto se daria no SAP, com o que realmente eu preciso saber que é a Inutilização de uma nota fiscal.
    Então o cenário seria este:
    O  usuário criou uma nota, e se deu conta que criou errada e precisa cancelá-la, a nota foi para a mensageria, porém esta (a mensageria)  por algum motivo, alguma falha na SEFAZ, o ambiente estava fora, algo parecido, ainda não tinha recebido resposta para a nota, se foi autorizada ou rejeitada, consequentemente o monitor de NF-e no SAP não foi atualizado, para esta nota na coluna Status da Ação, continua aparecendo a "engrenagem".
    Para que o usuário cancele esta nota no SAP e na sequencia peça a inutilização, tudo isso levando-se em conta que não obtivemos a resposta da SEFAZ, a sequencia de passos que ele tem que fazer é esta que coloco abaixo ? :
    1 - No monitor, seleciona a NF-e
    2 - Escolhe "Estorno antes da Autorização"
    3 - Na coluna ETAPA aparece a atividade "2"
    4 - Escolho "Estornar documento de Origem"
    5 - Enviar NF-e as Autoridades Fiscais
    E levando-se em conta que a SEFAZ não respondeu da 1a vez, que a nota não consta na base de dados dela, então a SEFAZ deve aprovar a inutilização.
    Pelo fato de ser uma outra mensageria, o processo acontece normalmente, não há nenhum desenvolvimento a ser feito do lado do ERP SAP para que esta situação seja atendida, a saída da solicitação de inutilização é feita normalmente pela função J_1B_NFE_XML_OUT, e no nosso caso aqui temos o PI como middleware que envia os dados para a mensageria NÃO - SAP. Nós já fizemos o desenvolvimento para atender a Inutilização quando se tratar do gap de numeração, em que usamos o programa J_1BNFECHECKNUMBERRANGES.
    Desculpe, se não fui muito claro anteriormente.
    Atenciosamente,
    Diógenes

  • Ajuda para fazer retorno de NF-e com mensageria não SAP

    Bom dia pessoal.
    Estamos fazendo um arquivo XML para uma mensageria não SAP e estamos criando isso com um enhancement point na função J_1B_NFE_XML_OUT chamando uma função Z para efetuar o download dos files.
    Agora estou começando a criar um programa que fará o retorno que ficara agendado em JOB, pois a mensageria irá gravar o arquivo de retorno em uma pasta definida no servidor. Nesse retorno eu vou carregar o arquivo da mensageria e atualizar no SAP.  Minha duvida é, para efetuar essa atualização no SAP, eu devo usar a função J_1B_NFE_XML_IN ou a função J_1B_NFE_UPDATE_ACTIVE? As duas atualizarão o status no monitor?
    Uma outra duvida, hoje o pessoal aqui usa uma BADI na J1B3N para quando efetuar a saida da NF, já emitir um boleto para ir junto com a NF. Estou pensando em passar esse procedimento para o programa retorno, caso a NF-e seja autorizada pela SEFAZ, porém o usuário quer que assim que autorizar a nota, seja emitido o boleto, então está pensando executar o job do programa retorno em menor tempo. Alguém ja passou por isso e teria uma sugestão melhor para fazer?
    Muito obrigado!

    Bom dia Fulvio,
    Tecnicamente a função J_1BNFE_XML_IN não é remota (RFC), pelo menos não é entregue assim.
    Independente disso a SAP espera que a IN_TAB seja o ponto de recepção dos retornos então existe handling exception e preenchimento de BAPIRET2 (com todos os erros que aconteceram) veja SAP Note 1362971.
    Atenciosamente, Fernando Da Ró

  • Layout 2.00 com mensageria "Z" - Aplicação de Notas no SAP ECC

    Olá pessoal,
    Estou participando de um projeto para implementar a versão 2.0 do XML em um cliente que não tem a mensageria startard (GRC).
    Já levantei as notas necessárias no SAP ECC (estão num total de 42).
    A mensageria Z, muito semelhante do Acelerador/GRC pois também foi desenvolvida em uma instância SAP com o PI como integrador, deve trabalhar da mesma forma que o GRC no sentido de permitir o envio das duas versões (1.10 e 2.00) em paralelo através da configuração de Business Place no SAP ECC.
    Minha dúvida é a seguinte:
    Há algum impacto para as execuções na versão 1.10 se aplicarmos as Notas OSS no SAP ECC num primeiro momento e depois começarmos as adequações na mensageria?
    Desde já agradeço,
    Daniela

    Olá Daniela,
    Aplicando as SAP notes, a estrutura do FM J_1B_NFE_XML_OUT (que é utilizado outras mensagerias - não SAP) é alterado com a inclusão de novos parâmetros de importação, porém estes são opcionais o que não irá impactar a solução de mensageria não standard.
    Lembre-se também de não alterar a versão do XML (IMG: Cross-Application Components, choose General Application Functions --> Nota Fiscal --> CNPJ Business Places --> Define Business Places).
    E caso as SAP notes relacionadas aos motivos de contingência estejam sendo aplicadas agora, será necessário que o funcional realize as configurações necessárias (motivos de contingência) conforme descrito na Note 1451966 - NF-e: contingency date, time and reason .
    At.
    David

  • Integrated Configurations com.sap.engine.interfaces.messaging.api.exception

    Hi guys,
    we are using PI 7.11.
    With this release local processing on the advanced adapter engine is possible, when using integrated configurations.
    This works fine.
    Lately I faced an error situation in an RFC to JDBC scenario, when one field doesn´t meet the conditions of the database.
    I tried to dig deeper to identify the incorrect value by switch on the trace in the receiver JDBC channel, as I did several times before.
    Afterwards I treied to restart the message.
    Following error occurs.
    com.sap.engine.interfaces.messaging.api.exception.ConfigException: Unable to retrieve interface determination with object ID ab1bf720bf2711dea7d2020000000030 from CPA cache.
    I made some test with integrated configurations (FTP to FTP) and come to the result that errors, which require changes on the communication channel e.g. wrong password etc. result in an new object in the CPA cache
    trying restart the failed message ends up in the error specified aboce.
    Anyone faced the same issue already?
    Kind regards
    Jochen

    HI Jochen,
    I feel that you should once go for a CPA Cache refresh from Adapter Engine and try executing your failed messages once again in the adapter engine.
    To do a CPA Cache Refresh from the Adapter Engine:
    To trigger a cache refresh from the individual Adapter Framework, open a browser window and enter the following URL:
    http://<host>:<port>/CPACache/refresh?mode=delta|full
    The Monitoring url is like this:
    http://<host>:<port>/CPACache
    Check this How-to Guide on Cache, it will be useful:
    http://www.sdn.sap.com/irj/scn/index?rid=/library/uuid/c0332b2a-eb97-2910-b6ba-dbe52a01be34&overridelayout=true
    Thanks
    Dhwani

  • SAP SNC Supplier Network Collaboration integration with SAP ERP via BizTalk - experiences?

    Hello,
    had anybody experience in integration of SAP SNC Supplier Network  Collaboration with SAP ERP via BizTalk Server?
    Versions: SAP ECC 6.0 Ehp5 SPS11, SAP SNC  current version (7.0?)
    We will have to integrate following processes:
    Master Data integration, PO Purchase Order, Forecast, SMI Supplier Managed Inventory
    Usually SAP takes an SAP PI middleware for this, where the full implementation can be downloaded from the SAP marketplace, but we want to avoid having an additional Integration Platform with maintenance etc.
    Are there experiences, success stories, pitfalls, issues to be known, recommendations, known efforts in this forum?
    Thanks in advance.
    Jens

    HI Jens,
    In our forum, we discussed topic about BizTalk & SAP Integration before, hope it helps you.BizTalk
    & SAP Integration
    Best regards,
    Angie
    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click
    HERE to participate the survey.

  • Remote-Conrol a COM-Application via JNI Error: RPC_E_WRONG_THREAD

    hi,
    we have written a DLL which launches and remotecontrols an application via Microsoft COM. This DLL is called by a Swing-GUI-Application via JNI. It works fine over years. Now we have rewritten our application as an rcp-plugin. The COM-Appplication still launches fine, but when I call a COM-function of the remote-controlled application i get back an error:
    RPC_E_WRONG_THREAD
    ...which means that the wrong threading model is used. Does anyone know about differnt threading models of a swing application and an rcp-plugin?
    thanks for your help
    robert

    Kapila_Shantha wrote:
    But they are saying that they can use and do program using it but they are using RHEL 4 . They are wrong.
    A well done JNI library, regardless of how it is used, should not cause system exceptions.
    That would be true whether you created the library or whether someone else creates it.
    Although if they don't wish to certify it for specific configurations then that could be the cause. If that and only that is the cause then you are out of luck.
    If the real problem is that you are using it incorrectly (which should still not cause that problem) then you need to figure out how to use it correctly.

  • Commands to FTDI virtual COM port via NI VISA interfere with communication with FTDI chip using D2XX drivers

    Hello!  
    I am trying to communicate with a DLP Design module DLP-USB1232H which uses an FTDI chip.  My program uses the D2XX drivers.  It works, but...
    In another program that runs at the same time, I'm communicating with another instrument via a virtual COM port (VCP) that uses an FTDI UART.  In this program, I use the VISA Serial Port functions.  It works, too, but...
    The first program has the capability of listing all the FTDI devices in the system prior to choosing the right one to communicate with.  When the VCP is plugged in, it lists it (FT232R USB UART) along with the DLP-USB1232H and communication with the latter device works.   But as soon as the second program sends a command through the VCP, the first program no longer "sees" any FTDI device.  It stops working.
    I have tried 2 different FTDI VCPs; one a standalone cable and the other built in to the instrument.
    I’m using Windows 7 32-bit.  My programs are both LabVIEW 8.5 executables. 
    Is VISA "taking over" the channel to the DLP-USB1232H?  Does someone who understands NI's implementation of VISA have any ideas on why VISA is doing this?  Or if something else is going on?
    I'm also interested in workaround ideas.  I've tried a "Prolific" VCP, but most drivers don't work and the one that doesn't give an error in Device Manager doesn't communicate with the instrument.  
    Cheers
    Halden
    Solved!
    Go to Solution.

    Halden,
    It really sounds like you have a resource conflict. That occurs when two programs or parts of programs try to use the same device or port at the same time.  Your Get Device Function probably tries to open a session with each port (as you increment the index). When it hits a port which is being used by the other driver, it cannot open the session and stops working? Have you examined the errors returned by each program? The VISA drivers will return an error when the port is in use.  I do not know about your program or drivers, but I would expect some kind of error.  Automatic error handling in LabVIEW will not catch errors from a driver if it does not translate them to LV error clusters. So do not count on automatic error handling, if you use it, to display all possible errors.
    Lynn

Maybe you are looking for

  • Forms 6i OLB example.

    Please can anyone tell me. How to link or attached OLB to 6i Form. 1, I have form in 6i and OLB which is running fine in Production. 2, When I open the form in Forms Builder its asking for OLB 3, I tried like webutil you drag and drop the OLB but its

  • Java as an exe file???

    Hi, can a java file be converted to an exe file so that the user doesnt have to run it via: java filename? rick

  • Listening to Songs on itune store, they skip

    I am trying to download songs from the itunes store and they are skipping.  Several I downloaded in the past skip also.

  • Workflow Manager Cumulative Update (February) error

    Hi, I've downloaded and installed Workflow Manager 1.0 Cumulative Update and Service Bus 1.0 Cumulative Update. But after installing the updates, I can't access the Library workflow settings page. I'm getting unexpected error. Then after investigatin

  • Servlet question, pls help

    We have a jsp page with servlet works well in a server. Now we need to move it to another server (server2). I copied jsp page and a jar file that compiles all the class files (servlet) into the server2 and modified web.xml file in server2 too for ser