NAST OBJKY reference

Hi all,
In table NAST, field OBJKY is filled with a document number in reference to the application KAPPL. Is there a way to know which object is used to populate the field OBJKY. That is to say : is there a table, or a way to know that for an application EF, OBJKY is filled with EKKO-EBELN ?
Thanx,
Olivier

try table T681Z.... you will get the table..
try table T681B... you will get the description of the application.
Hope it is useful...

Similar Messages

  • Length mismatch for NAST-OBJKY and EKKO-EBELN

    Hi All,
    I am using Table NAST,and by using FOR ALL Entries with table ekko I am trying to use OBJKY = it_ekko-ebeln.But I am getting error message as length is different.when i checked OBJKY is of length 25 and EBELN is of lenght 10.Please help me to solve this problem.I tried to take a local variable but I am not able to use it.
    here is my code
    IF it_ekko IS NOT INITIAL .
        SELECT kappl    " Application for message conditions
               objky    " Object Key
               kschl    " Message type
               spras    " Message language
               parnr    " Message partner
               parvw    " Partner function
               erdat    " Date on which status record was created
               eruhr    " Time at which status record was created
               vstat    " Processing status of message
          FROM nast
          INTO TABLE it_nast
         FOR ALL ENTRIES IN it_ekko
          WHERE kappl = gc_apps
           AND objky = it_ekko-ebeln
            AND kschl IN s_kschl.
        IF sy-subrc = 0.
          SORT gt_nast BY kappl objky.

    Declare Like this,
    data : begin of it_ekko,
    ebeln type nast-objky,
    end of it_ekko.
    Regards,
    Dileep .C

  • Quary on NAST-OBJKY.

    Hi All,
    I am coding a driver program for a Smartform,layout is already done.But as I am a beginner for this I dont have any idea abut the TRIGGERING of a form.So my qustions are-
    1.How the <b>SMARTFORMS</b> are <b>TRIGGERED</b> and when?
    2.What is <b>NAST-OBJKY</b> , how it is related to <b>TRIGGERING</b>?

    Hi John,
    Thx for clearing my conception.I have one more qustion. In program RLB_INVOICE function module <b>SSF_FUNCTION_MODULE_NAME</b> is called , and under the import parameter <b>LF_FM_NAME</b> is passed.Again it is called .But I think this is not a standard FM.Why it is called again?
    For your convenience I am attaching the code below.
    CALL FUNCTION 'SSF_FUNCTION_MODULE_NAME'
             EXPORTING  formname           = lf_formname
                    variant            = ' '
                    direct_call        = ' '
             IMPORTING  fm_name            = lf_fm_name
             EXCEPTIONS no_form            = 1
                        no_function_module = 2
                        OTHERS             = 3.
        IF sy-subrc <> 0.
      error handling
          cf_retcode = sy-subrc.
          PERFORM protocol_update.
        ENDIF.
    CALL FUNCTION lf_fm_name
               EXPORTING
                          archive_index        = toa_dara
                          archive_parameters   = arc_params
                          control_parameters   = ls_control_param
                    mail_appl_obj        =
                          mail_recipient       = ls_recipient
                          mail_sender          = ls_sender
                          output_options       = ls_composer_param
                          user_settings        = space
                          is_bil_invoice       = ls_bil_invoice
                          is_nast              = nast
                          is_repeat            = repeat
         importing  document_output_info =
                    job_output_info      =
                    job_output_options   =
               EXCEPTIONS formatting_error     = 1
                          internal_error       = 2
                          send_error           = 3
                          user_canceled        = 4
                          OTHERS               = 5.
    Regards.
    Rajarshi.

  • NAST-OBJKY

    How to get NAST-OBJKY based on spool number
    can any body help me.
    regards
    raadha

    Hi,
    There is no direct way to get it. Fire a select query by using a join condition for the tables NAST, TSP01 and TSP03 for the particular spool number. I havnt tried this, but should work i guess. Let me know.
    Nayan

  • Reference table of structure LBBIL_INVOICE ?

    Hi Expert,
    I want to create smartform based on standard SAP program.
    Printing Program : RLB_INVOICE
    Smartforms : SF_LB_INVOICE
    I have problem during change smartform. The interface of smartform is IS_BIL_INVOICE TYPE LBBIL_INVOICE. This structure contain of other table type or other structure. I think this structure have complete data. But functional design always create design using database table that I must fetch the data.
    Is there any body can tell me what is reference table of each element of structure LBBIL_INVOICE ?
    Thanks beforehand.

    Hi ,
    These structures are deep structures and you  will have  the table  entered  as a field of this structure .
    All the values are populated in these structures . Else copy the standard driver program  and  the key field is always populated in nast table get the keyfield from nast table ( nast  structure gets populated  autmatically  check in the std driver program )
    eg   (   move nast-objky(10) to g_ebeln   )
    based on this key field fetch all the other values you require in the driver program and pass it to your smart form .But i must say this is  not a smart  thing to do if you already have all the data available in the  standard structure .
    give your  driver program and smartform name in NACE txn. also define the output type.  all the other data  retrival  can also be done in the code editor of smart form  in case you need some other values at a later stage.here is the sample code
    FORM GET_DATA .
    check not nast-objky is initial.
      move nast-objky(10) to g_ebeln.
    ENDFORM.                    " GET_DATA
    *&      Form  GET_FORMNAME
          text
    -->  p1        text
    <--  p2        text
    FORM GET_FORMNAME .
    select single sform
        from tnapr
        into tnapr-sform
       where kschl = nast-kschl " Output Type
         and nacha = nast-nacha " Message transmission
         and kappl = nast-kappl." Application
      if sy-subrc = 0.
        g_formname = tnapr-sform.
    endif.
    ENDFORM.                    " GET_FORMNAME
    *&      Form  ZCALLFORM
          text
    -->  p1        text
    <--  p2        text
    FORM ZCALLFORM .
    call function 'SSF_FUNCTION_MODULE_NAME'
      exporting
        formname                 = g_formname
      VARIANT                  = ' '
      DIRECT_CALL              = ' '
    importing
       fm_name                  = g_fmname
    EXCEPTIONS
       NO_FORM                  = 1
       NO_FUNCTION_MODULE       = 2
       OTHERS                   = 3
    if sy-subrc <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
             WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    endif.
    call function g_fmname
      exporting
      ARCHIVE_INDEX              =
      ARCHIVE_INDEX_TAB          =
      ARCHIVE_PARAMETERS         =
      CONTROL_PARAMETERS         =
      MAIL_APPL_OBJ              =
      MAIL_RECIPIENT             =
      MAIL_SENDER                =
      OUTPUT_OPTIONS             =
      USER_SETTINGS              = 'X'
        im_ebeln                   = g_ebeln
    IMPORTING
      DOCUMENT_OUTPUT_INFO       =
      JOB_OUTPUT_INFO            =
      JOB_OUTPUT_OPTIONS         =
    exceptions
       formatting_error           = 1
       internal_error             = 2
       send_error                 = 3
       user_canceled              = 4
       others                     = 5
    if sy-subrc <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    endif.
    ENDFORM.                    " ZCALLFORM
    *&      Form  ZUPDATENAKT
          text
    -->  p1        text
    <--  p2        text
    FORM ZUPDATENAKT .
    nast-vstat = 1.
      nast-usnam = sy-uname.
      nast-datvr = sy-datum.
      nast-uhrvr = sy-uzeit.
      call function 'RV_MESSAGE_UPDATE_SINGLE'
        exporting
          msg_nast = nast.
    ENDFORM.                    " ZUPDATENAKT

  • Duplicando registro tabela NAST após chamada J_1BNFE_CALL_RSNAST00

    Boa tarde pessoal,
    estava conversando com o Fernando nesta [Thread|; e resolvi abrir uma nova thread.
    Estava implementando a badi de impressão do danfe e notei um comportamento estranho.
    Após gerar uma NFe, é gerado um registro na NAST.
    Na sequencia, executo o FM J_1B_NFE_XML_IN para simular o aceite desta NFe, o que acarreta na chamada da badi de impressão e na minha badi tenho a chamada p/ o FM J_1BNFE_CALL_RSNAST00.
    Dentro deste FM, ele move alguns parâmetros de entrada para a NAST e chama o form einzelnachricht, que chama tnaprlesen_, optischearchivierung_, programmaufrufen_, protocolstore_ e finalmente o nastupdate_.
    Neste ponto do programa, a chave que tenho no header da tabela NAST é diferente da que já consta na tabela do bd.
    No BD tenho este registro na NAST:
    MANDT     321
    KAPPL     NF
    OBJKY     0003347752
    KSCHL     ZNFE
    SPRAS     E
    PARNR                                                                               
    PARVW                                                                               
    ERDAT     06/24/2009
    ERUHR     14:38:41
    e no programa, no form nastupdate_, tenho o header da NAST assim:
    MANDT
    KAPPL     NF
    OBJKY     0003347752
    KSCHL     ZNFE
    SPRAS     
    PARNR     
    PARVW     
    ERDAT     00000000
    ERUHR     000000
    Sendo assim, quando ele dá o update nast. ele dá sy-subrc = 4, e na sequencia, o código trata if sy-subrc ne 0, insert nast. Com isso tenho 2 registros na NAST pra mesma NF, um com o status VSTAT = 1, mas com o SPRAS/ERDAT/ERUHR não preenchidos e o outro, o "original", com tudo preenchido porém com o status VSTAT = 0.
    Olhando o Spool na SP01 eu vejo a NFe "impressa" apenas uma vez, o que está correto. Mas o que me incomoda é que ele acaba gerando registros duplicados.
    Segue meu código da BADI:
      IF  i_active-code EQ '100'         "NF-e autorizada
      AND i_active-printd IS INITIAL     "só imprimir automaticamente se ainda não foi impressa
      AND i_active-cancel IS INITIAL     "não faz sentido imprimir autom. se ela foi cancelada
      AND i_active-conting_s IS INITIAL. "não faz sentido imprimir autom. se ela foi alternada
                                         "p/conting. pois deverá ser cancelada
        CALL FUNCTION 'J_1BNFE_CALL_RSNAST00'
        EXPORTING
          I_ACTIVE = i_active
          I_DIMME  = 'X'
          I_PRINTER = vl_printer
        EXCEPTIONS
          no_printer = 1
          others = 2.
        COMMIT WORK.
        IF sy-subrc = 0.
          CALL FUNCTION 'J_1B_NFE_ERROR_PROTOKOLL'
          EXPORTING
            i_docnum = i_active-docnum.
        ENDIF.
      ENDIF.
    Para "resolver" esse pequeno problema (ao meu ver, não sei se está correto ou não este comportamento), criei um FM Z com o seguinte código:
    FUNCTION ZBR_J_1BNFE_CALL_RSNAST00.
    ""Local Interface:
    *"  IMPORTING
    *"     VALUE(I_ACTIVE) TYPE  J_1BNFE_ACTIVE
    *"     VALUE(I_KAPPL) TYPE  NAST-KAPPL DEFAULT 'NF'
    *"     VALUE(I_NACHA) TYPE  NAST-NACHA DEFAULT '1'
    *"     VALUE(I_DIMME) TYPE  NAST-DIMME DEFAULT 'X'
    *"     VALUE(I_PRINTER) TYPE  RSPONAME OPTIONAL
    *"  EXCEPTIONS
    *"      PRINT_ERROR
    TABLES: nast.
    SELECT SINGLE *
        FROM nast
       WHERE kappl = i_kappl AND
             objky = i_active-docnum AND
             kschl = i_active-form AND
             nacha = i_nacha AND
             vstat = '0'.
    start printing
      nast-kappl = i_kappl.
      nast-objky = i_active-docnum.
      nast-kschl = i_active-form.
      nast-nacha = i_nacha.          "1 = print output
      "nast-ldest = i_printer.
      "nast-dimme = i_dimme.          "X = print immidiately
      PERFORM einzelnachricht IN PROGRAM rsnast00 USING sy-subrc.
      IF NOT sy-subrc IS INITIAL.
        MESSAGE i230(8b) with i_active-docnum RAISING print_error. "#EC *
      ENDIF.
    ENDFUNCTION.
    e na BADI, o chamei desta forma:
    CALL FUNCTION 'ZBR_J_1BNFE_CALL_RSNAST00'
        IN BACKGROUND TASK
        EXPORTING
          i_active = i_active
        EXCEPTIONS
          no_printer = 1
          others = 2.
    Desta maneira, não ocorreu a duplicação dos registros da NAST e a nota também foi impressa OK.
    A minha dúvida é se realmente o comportamento esperado utilizando o primeiro procedimento é duplicar o registro na NAST ou se pode ser que tenha algo errado no meu sistema(SAP_APPL 602 SP01) na hora da chamada da RSNAST00.

    parte 1
    Boa tarde pessoal,
    estava conversando com o Fernando nesta [Thread|; e resolvi abrir uma nova thread.
    Estava implementando a badi de impressão do danfe e notei um comportamento estranho.
    Após gerar uma NFe, é gerado um registro na NAST.
    Na sequencia, executo o FM J_1B_NFE_XML_IN para simular o aceite desta NFe, o que acarreta na chamada da badi de impressão e na minha badi tenho a chamada p/ o FM J_1BNFE_CALL_RSNAST00.
    Dentro deste FM, ele move alguns parâmetros de entrada para a NAST e chama o form einzelnachricht, que chama tnapr_lesen, optische_archivierung, programm_aufrufen, protocol_store e finalmente o nast_update.
    Neste ponto do programa, a chave que tenho no header da tabela NAST é diferente da que já consta na tabela do bd.
    No BD tenho este registro na NAST:
    MANDT     321
    KAPPL     NF
    OBJKY     0003347752
    KSCHL     ZNFE
    SPRAS     E
    PARNR                                                                               
    PARVW                                                                               
    ERDAT     06/24/2009
    ERUHR     14:38:41
    e no programa, no form nastupdate_, tenho o header da NAST assim:
    MANDT
    KAPPL     NF
    OBJKY     0003347752
    KSCHL     ZNFE
    SPRAS     
    PARNR     
    PARVW     
    ERDAT     00000000
    ERUHR     000000
    Sendo assim, quando ele dá o update nast. ele dá sy-subrc = 4, e na sequencia, o código trata if sy-subrc ne 0, insert nast. Com isso tenho 2 registros na NAST pra mesma NF, um com o status VSTAT = 1, mas com o SPRAS/ERDAT/ERUHR não preenchidos e o outro, o "original", com tudo preenchido porém com o status VSTAT = 0.
    Olhando o Spool na SP01 eu vejo a NFe "impressa" apenas uma vez, o que está correto. Mas o que me incomoda é que ele acaba gerando registros duplicados.
    continua
    Edited by: Jose Nunes on Jun 24, 2009 5:00 PM
    Edited by: Jose Nunes on Jun 24, 2009 5:01 PM

  • UPDATE NAST

    Hi all, i'm using this coding to update nast table for Purchase Order .This coding is not working.
    please help me to solve this problem.
    Your help is greatly appreciated.
    tables nast.
    nast-MANDT            =   sy-mandt.
    nast-KAPPL            =   'EF'.
    nast-OBJKY            =   '4100000477'.
    nast-KSCHL            =   'NEU'.
    nast-SPRAS            =   sy-langu.
    nast-PARNR            =   '0000100165'.
    nast-PARVW            =   'LF'.
    nast-ERDAT            =   sy-datum.
    nast-ERUHR            =   sy-uzeit.
    nast-NACHA            =   '1'.
    nast-ANZAL            =   '0'.
    nast-VSZTP            =   '1'.
    nast-MANUE            =   'X'.
    nast-USNAM            =   sy-UNAME.
    nast-VSTAT            =   '0'.
    nast-LDEST            =   'HOIT'.
    nast-TDID             =   'BEWG'.
    nast-TDSPRAS          =   sy-langu.
    nast-NAUTO            =   'X'.
    nast-TDRECEIVER       =   sy-UNAME.
    nast-TDCOVTITLE       =   'New Purchase Order Printout'.
    CALL FUNCTION 'NAST_SAVE_OBJECT'
      EXPORTING
        pi_nast              = nast
       PI_LINK_OBJECT       = 'X'
       PI_PROCESSING        = 'X'
    EXCEPTIONS
       NOT_SAVED            = 1
       OTHERS               = 2
    IF sy-subrc <> 0.
      write: / 'NOT SAVED'.
    ELSE.
      write: / 'SAVED'.
    ENDIF.
      IF sy-subrc = 0.
        COMMIT WORK.
        write / 'TABLE "NAST" WAS UPDATED'.
      else.
        rollback work.
        write / 'TABLE "NAST" WAS NOT UPDATED'.
      endif.

    Hi,
    The following piece of coding should be changed as
    IF sy-subrc <> 0.
    write: / 'NOT SAVED'.
    ELSE.
    write: / 'SAVED'.
    ENDIF.
    IF sy-subrc = 0.
    COMMIT WORK.
    write / 'TABLE "NAST" WAS UPDATED'.
    else.
    rollback work.
    write / 'TABLE "NAST" WAS NOT UPDATED'.
    endif.
    <u>Changed code:</u>
    IF sy-subrc <> 0.
    rollback work.
    write / 'TABLE "NAST" WAS NOT UPDATED'.
    ELSE.
    COMMIT WORK.
    write / 'TABLE "NAST" WAS UPDATED'.
    ENDIF.

  • How to use Nast in program

    Hello,
            I want to use the attribute OBJKY in NAST.But how do I use the structure NAST in my prgoram.

    Hi shah,
    Declare tables : nast.
    Then data declaration for nast fields.
    use p_vbeln in your select statement.
    Then,
    FORM populate_nast.
      CLEAR: nast-uhrvr ,
             nast-cmfpnr,
             nast-datvr .
      nast-mandt = '320'.
      nast-kappl = 'V3'.
      nast-kschl = 'ZSMT'.
      nast-objky =  p_vbeln.
      nast-ldest = 'LOCL'.
      nast-anzal =  1.
      nast-nacha = '1'.
      nast-vsztp = '4'.
      nast-spras = 'E'.
      nast-vstat = '0'.
      nast-manue = 'X'.
      nast-dimme = ' '.
      nast-erdat = sy-datum.
      nast-eruhr = sy-uzeit.
      nast-usnam = sy-uname.
      nast-tdreceiver = sy-uname.
      CONCATENATE sy-uzeit+2(4) 'PDF' INTO nast-dsnam.
    endform.
    Revert back if you need any help.
    Re,Manas

  • ABOUT NAST RSNAST00

    Hi,
      How ABOUT NAST RSNAST00 this are linked with ABAP Code?
    Example if any?
    Thanks
    Avi

    Hi
      Check this one The simplest way to create IDocs, is to write an ABAP. The individual ABAP can either be a triggering ABAP which runs at certain events, e.g. every night, or it can be an ABAP which does the complete IDoc creation from scratch.
    Triggering ABAP
    A triggering ABAP would simply try to determine which IDocs need sending and call the appropriate IDoc creation routines.
    ABAP creates the whole IDoc
    You may also imagine the ABAP to do all the job. As this is mostly reinventing the wheel, it is not really recommended and should be reserved to situation, where the other solution do not provide an appropriate mean.
    1.1     NAST Messages Based Outbound IDocs
    You can use the R/3 message concept to trigger IDocs the same way as you trigger SAPscript printing.
    One of the key tables in R/3 is the table NAST. This table records reminders written by applications. Those reminders are called messages.
    Applications write messages to NAST, which will be processed by a message handler
    Every time when an applications sees the necessity to pass information to a third party. a message is written to NAST. A message handler will eventually check the entries in the table and cause an appropriate action.
    EDI uses the same mechanism as printing
    The concept of NAST messages has originally been designed for triggering SAPscript printing. The very same mechanism is used for IDocs, where the IDoc processor replaces the print task, as an IDoc is only the paperless form of a printed document.
    Condition technique can mostly be used
    The messages are usually be created using the condition technique, a mechanism available to all major R/3 applications.
    Printing, EDI and ALE use the same trigger
    The conditions are set up the same way for any output media. So you may define a condition for printing a document and then just change the output media from printer to IDoc/EDI or ALE.
    Figure 1:     Communicating with message via table NAST
    NAST messages are created by application by calling function module MESSAGING
    Creating NAST messages is a standard functionality in most of the SAP core applications. Those applications - e.g. VA01, ME21 - perform calls to the central function module MESSAGING of group V61B. The  function module uses customizing entries, mainly those of the tables T681* to T685*.
    NAST contains object key, sender and receiver
    A NAST output message is stored as a single record in the table NAST. The record stores all information that is necessary to create an IDoc. This includes mainly an object key to identify the processed object and application to the message handler and the sender and receiver information.
    Programs RSNAST00 and RSNASTED provide versatile subroutines for NAST processing
    The messages are typically processed by
    FORM ENTRY in PROGRAM RSNAST00.
    If we are dealing with printing or faxing and
    FORM EDI_PROCESSING in PROGRAM RSNASTED.
    If we are dealing with IDocs
    FORM ALE_PROCESSING in PROGRAM RSNASTED.
    If we are dealing with ALE.
    The following piece of code does principally the same thing as RSNAST00 does and makes full use of all customizing settings for message handling.
    FORM einzelnachricht IN PROGRAM RSNAST00
    TABLES: NAST.
    SELECT * FROM NAST ...
    PERFORM einzelnachricht IN PROGRAM RSNAST00
    Programs are customized in table TNAPR
    The processing routine for the respective media and message is customized in the table TNAPR. This table records the name of a FORM routine, which processes the message for the chosen media and the name of an ABAP where this FORM is found.
    1.2     The RSNAST00 ABAP
    The ABAP RSNAST00 is the standard ABAP, which is used to collect unprocessed NAST message and to execute the assigned action.
    RSNAST00 is the standard batch collector for messages
    RSNAST00 can be executed as a collector batch run, that eventually looks for unprocessed IDocs. The usual way of doing that is to define a batch-run job with transaction SM37. This job has to be set for periodic processing and start a program that triggers the IDoc re-sending.
    RSNAST00 processes only messages of a certain status
    Cave! RSNAST00 will only look for IDocs which are set to NAST-VSZTP = '1' or '2' (Time of processing). VSZPT = '3' or '4' is ignored by RSNAST00.
    For batch execution a selection variant is required
    Start RSNAST00 in the foreground first and find the parameters that match your required selection criteria. Save them as a VARIANT and then define the periodic batch job using the variant.
    If RSNAST00 does not meet 100% your needs you can create an own program similar to RSNAST00. The only requirement for this program are two steps:
    Read the NAST entry to process into structure NAST
    tables nast.
    data: subrc like sy-subrc.....
    select from NAST where .......
    then call FORM einzelnachricht(rsnast00) to process the record
    PERFORM einzelnachricht(rsnast00) USING subrc.
    1.3     Sending IDocs Via RSNASTED
    Standard R/3 provides you with powerful routines, to trigger, prepare and send out IDocs in a controlled way. There are only a few rare cases, where you do not want to send IDocs the standard way.
    The ABAP RSNAST00 is the standard routine to send IDocs from entries in the message control. This program can be called directly, from a batch routine with variant or you can call the FORM einzelnachricht_screen(RSNAST00) from any other program, while having the structure NAST correctly filled with all necessary information.
    RSNAST00 determines if it is IDoc or SAPscript etc.
    If there is an  entry in table NAST, RSNAST00 looks up the associated processing routine in table TNAPR. If it is to send an IDoc with standard means, this will usually be the routine RSNASTED(EDI_PROCESSING) or RSNASTED(ALE_PROCESSING) in the case of ALE distribution.
    RSNASTED processes IDocs
    RSNASTED itself determines the associated IDoc outbound function module, executes it to fill the EDIDx tables and passes the prepared IDoc to the port.
    You can call the standard processing routines from any ABAP, by executing the following call to the routine. You only have to make sure that the structure NAST is declared with the tables statement in the calling routine and that you fill at least the key part and the routine (TNAPR) information before.
    TABLES NAST.
    NAST-MANDT = SY-MANDT.
    NAST-KSCHL = 'ZEDIK'.
    NAST-KAPPL = 'V1'.
    NAST-OBJKY = '0012345678'.
    NAST-PARNR = 'D012345678'.
    PERFORM einzelnachricht_screen(RSNAST00).
    Calling einzelnachricht_screen determines how the message is processed. If you want to force the IDoc-processing you can call it directly:
    TNAPR-PROGN = ''.
    TNAPR-ROUTN = 'ENTRY'.
    PERFORM edi_processing(RSNASTED).
    1.4     Sending IDocs Via RSNAST00
    Here is the principle flow how RSNAST00 processes messages for IDocs.
    Figure 2:     Process logic of RSNAST00 ABAP
    1.5     Workflow Based Outbound IDocs
    Unfortunately, there are application that do not create messages. This is especially true for master data applications. However, most applications fire a workflow event during update, which can easily be used to trigger the IDoc distribution.
    SWE_EVENT_CREATE
    Many SAP R/3 applications issue a call to the function SWE_EVENT_CREATE during update. This function module ignites a simple workflow event.
    Workflow is a call to a function module
    Technically a workflow event is a timed call to a function module, which takes the issuing event as the key to process a subsequent action.
    Applications with change documents always trigger workflow events
    If an application writes regular change documents (ger.: Änderungsbelege) to the database, it will issue automatically a workflow event. This event is triggered from within the function CHANGEDOCUMENT_CLOSE. The change document workflow event is always triggered, independent of the case whether a change document is actually written.
    Workflow coupling can be done by utility functions
    In order to make use of the workflow for IDoc processing, you do not have to go through the cumbersome workflow design procedure as it is described in the workflow documentation. For the mentioned purpose, you can register the workflow handler from the menu, which says Event Coupling from the BALD transaction.
    Workflow cannot easily be restarted
    Triggering the IDoc from a workflow event has a disadvantage: if the IDoc has to be repeated for some reason, the event cannot be repeated easily. This is due to the nature of a workflow event, which is triggered usually from a precedent action. Therefore you have to find an own way how to make sure that the IDoc is actually generated, even in the case of an error. Practically this is not a very big problem for IDocs. In most cases the creation of the IDoc will always take place. If there is a problem, then the IDoc would be stored in the IDoc base with a respective status. It will shown in transaction WE05 and can be resend from there.</b>
    Thanks
    Manju

  • Nast table and spras language in it

    hi
    i want to know how the data in nast table is populated
    as i have a bwlow code
      LANGUAGE     = NAST-SPRAS.
      SHIPMENT_NUM = NAST-OBJKY.
    CALL FUNCTION 'RV_SHIPMENT_PRINT_VIEW'
    now the problme is that the language as cming from n ast spras is 1 but it should be EN i want to know how the data is populated in this nast table and what does the above code signefies......
    LANGUAGE     = NAST-SPRAS.
      SHIPMENT_NUM = NAST-OBJKY.
    how the data in nast-spras is poplulated and wht is nast-objky and how data is populated in it
    and is it  possible to change data for this specific case ie nast-spras to en i want to  hard code...
    regards
    Arora

    Hi,
    For language, which is in most tables 1 char instead of 2, there are 2 conversion routines which you can use in your code:
    CONVERSION_EXIT_ISOLA_INPUT    Convert two-digit ISO language -> one-digit SAP language key
    CONVERSION_EXIT_ISOLA_OUTPUT   Convert One-digit SAP Lang. Key to Two-digit ISO Lang. Key
    You can also check table T002 which contains for SPRAS (1 char) the 2 char code in field  LAISO. The 2 char field is used mostly for display purposes. For example, EN is stored as E, but EN is nicer to display.
    Please reward points if usefull.
    Regards,
    Bart

  • Object key in NAST

    Hi All ,
    when an output type is triggered , an entry in NAST gets created . We have an object key in that entry.
    My question is where that object key is attached .
    For example ,in V1 application, document number(VBELN)  is the  the object key .
    In case of  RV application, vguid  is the  the object key .
    I want know, based on what, and at what point, the object key is decided .
    Regards
    Rudra

    Hi,
    Good question, after giving some thought, this is how I think it is derived.
    Every object refers to a database table example Order refers to VBAK, Invoice to VBRK and Accounting document to BKPF. these tables have a primary key. The NAST-OBJKY is derived using the combination of the primary key.
    Example :
    Object          Table    Key                Object key in NAST
    Sales order       VBAK  VBELN                  = NAST-OBJKY.
    Sales order item,      VBAP  VBELN + POSNR            = NAST, combi of this is OBJKY.
    Accounting document     BKPF  BUKRS + BELNR + GJAHR   = NAST-OBJKY
    And so on
    Note this is just my assumption, and I may be wrong. So if anyone has anymore thoughts, please share.
    regards,
    Advait

  • NAST  Table

    Hi,
       I got a one requirement. What is the use of NAST table?Now iam creating one custom table.In the custom table Customer Number(Kunnr) and Billing Document(VBELN) is there.And NAST table provided and they given for customer number(NAST-PARNR) And Billing Document Number(NAST-OBJKY).So what is the
    use of NAST table.Why they provide NAST-PARNR and NAST-OBJKY insted of
    customer number and billing document.Please give me reply?
    Thanks & Regards,
    sairam

    I Don't understadn what your requirement is , but the standard procedure is this.
    for example take Purchase order.
    Me21n is the transaction.
    When you save the purchase order, an output type which is attached to the ME21n transaction will trigger the PO Output driver program. The data in the ME21n transaction is transferred to the PO Driver program in NAST structure.
    Once the PO's outpt is issued succesfully, NAST table will be updated with the PO Number as Object Key. for that particular Output type.
    Regards,
    Ravi

  • NAST read from workarea or ???

    Hi experts
    in a Smartform-printreport (like RLE_DELNOTE) I have to check if any KSCHL (ex. ZLMA or ZLMW) is also in the NAST.
    this is no problem using:
      DATA: lt_nast               TYPE TABLE OF nast.
      DATA: ls_nast               LIKE LINE  OF lt_nast.
        IF nast-kschl EQ 'ZLAK'.
          SELECT *
            FROM nast
            INTO CORRESPONDING FIELDS OF TABLE lt_nast
           WHERE kappl EQ nast-kappl
             AND objky EQ nast-objky
             AND ( kschl EQ 'ZLMA' OR kschl EQ 'ZLMW' ).
        ENDIF.
    BUT
    on creaton of the delivery-note a output type (ZLAK) is generated with NAST-VSZTP 4 (Send immediately).
    on this time the NAST isn't already committed and the abap-coding fails
    where can I get the NAST ?
    regards
    Mark
    Edited by: Mark Krähenbühl on Jun 14, 2010 2:20 PM

    Hello Mark,
    Is there any reason why the timing in NAST-VSZTP  has to be sent immediately (4 ) ? Is it possible to change the condition records for the output type so that the timing is changed to be processed by background job ( RSNAST00 for V2 and the o/p type(s) ) . I had a similar situation and as the data is not committed in NAST , I tested with changed timings and advised the functional team to change timing for the o/p type config.
    Thanks
    Vikas

  • NAST contents in printing program

    Hi,
    I'm having problems in a printing program associated to an output type of the billing document. The functional team has customized the printing program, the entry form and the sapscript form but in the printing program i'm reading the billing document number from NAST-OBJKY but it seams that NAST-OBJKY has no value. Does anyone had already this problem and knows how to solve it ? Does anyone know if it's necessary to do some aditional customizing in order to have access to the contents of NAST ? Does anyone knows if any procedure is necessary in the printing program in order to have access to NAST contents ( something like the way the printing program is strucured ) ?
    Thanks,
    Paulo Sousa

    Hi,
    The problem was i filled options parameter in OPEN_FORM function module and i've forgot to fill the field ITCPO-TDPROGRAM.
    Thank you anyway, i'll close this message.
    Best regards,
    Paulo Sousa

  • How to use NAST entry inside a printing program.

    Hi,
         I am writing a program to print an invoice using smartform.
    I am refering NAST-OBJKY to get the invoice No.
    My program throwing syntax error that NAST-OBJKY is unknown.
    But if I copy a standard printing program, and use it different name, there is no error.
    Thank U for Ur time.
    Cheers,
    Sam

    hi
    u r using the correct on but first movethe value to another varable like
    VBRK-VBELN
    USE THIS INCLUDE IN U R PROGRAM <b>RVADTABL</b>
    SAM the reason for u r problem is NAST is not declared in u r program... but in the sandard program they have declared it in the include RVADTABL
    Message was edited by:
            Naresh Reddy

Maybe you are looking for

  • Keynote has unexpected error when copying a table- how do I report this?

    I looked for a place to send a report of this error in Keynote 09, but can't find the place to do so.  Seems a simple operatoin like this should not cause a fatal error.

  • Write to Spreadsheet vi does not work when opened on my laptop.

    Hello, I have a very simple vi that collects data and writes to a spreadsheet. It works perfectly on my desktop computer but when I open with my laptop it does not write or give any indication that it's working.I know the vi is running but nothing ha

  • Connect to SFTP via proxy

    This is most definitely a network issue rather than a specific Dreamweaver issue. Until recently I was able to use Secure FTP via Dreamweaver but this appears to have been restricted by network admin for some reason. That said, I'm still able to conn

  • How to open image in PhotoShopCC2014 from Yosemite Photo?

    From iPhoto I was able to drag and drop images to PhotoShop icon in the dock to open the image.  This does not appear to work when I upgraded to Yosemite which provides Photo to replace iPhoto.  Is there a way to do this without going to the PhotoLib

  • Power Supply "Powered-Off" State

    I have power supplies in Slot 1 and Slot 2. Both power supplies show fully operable (power, voltage, etc) in details, however the Slot 1 power supply shows "Powered-Off" I have tried both N+1 and Non-Redundant power policies. Thanks for help in advan