Creation of PGI using BDC for tc VL02N is not happening..

Hi All,
i need to do Post Goods Issue (PGI) thro' BDC and after that i need to update the flag in Ztable.
its giving Success message and updating the database also.
but its not issuing the PGI.and further i want to create billing doc.So its compulsory to me to post PGI.
if i look into the BDCMSGCOLL structure its giving "NO BATCH INPUT DATA FOR SCREEN"? why this is happening?
please let me know immediately....
REFRESH: tt_bdcmsgcoll .
  CALL FUNCTION 'CONVERSION_EXIT_ALPHA_INPUT'
    EXPORTING
      input  = wa_created-document_numb
    IMPORTING
      output = wa_created-document_numb.
  REFRESH tt_bdcdata.
  PERFORM bdc_dynpro      USING text-001 text-002.
  PERFORM bdc_field       USING text-008
                               text-014.
  PERFORM bdc_field       USING text-009
                                text-011.
  PERFORM bdc_field       USING text-014
                                wa_created-document_numb.
  PERFORM bdc_dynpro      USING text-001 text-003.
  PERFORM bdc_field       USING text-009
                                text-036.
  PERFORM bdc_field       USING text-025
                                sy-datum.
  PERFORM bdc_field       USING text-008
                                text-035.
  PERFORM bdc_field       USING text-037
                                sy-datum.
  PERFORM bdc_field       USING text-038
                                text-029.
  PERFORM bdc_field       USING text-016
                                c_x.
  CALL TRANSACTION c_t_del USING tt_bdcdata
                                MODE c_m
                                UPDATE c_u
                                MESSAGES INTO tt_bdcmsgcoll .
  SORT tt_bdcmsgcoll BY msgtyp.
  READ TABLE tt_bdcmsgcoll INTO wa_bdcmsgcoll WITH KEY msgtyp = c_e.
  IF sy-subrc EQ 0.
    LOOP AT tt_bdcmsgcoll INTO wa_bdcmsgcoll WHERE msgtyp = c_e.
      CALL FUNCTION 'FORMAT_MESSAGE'
        EXPORTING
          id        = wa_bdcmsgcoll-msgid
          lang      = text-010
          no        = wa_bdcmsgcoll-msgnr
          v1        = wa_bdcmsgcoll-msgv1
          v2        = wa_bdcmsgcoll-msgv2
          v3        = wa_bdcmsgcoll-msgv3
          v4        = wa_bdcmsgcoll-msgv4
        IMPORTING
          msg       = v_msg
        EXCEPTIONS
          not_found = 1
          OTHERS    = 2.
      IF sy-subrc <> 0.
      ENDIF.
      WRITE :/ v_msg.
    ENDLOOP.
  ELSE.
    MOVE : c_x TO wa_worklist-pgi_flag.
    READ TABLE tt_epit INTO wa_epit WITH KEY epi_id = wa_worklist-epi_id epi_sr = wa_worklist-epi_sr.
    IF sy-subrc EQ  0.
      MODIFY tt_epit FROM wa_worklist TRANSPORTING pgi_flag WHERE epi_id = wa_worklist-epi_id AND epi_sr = wa_worklist-epi_sr.
    ELSE.
      APPEND wa_worklist TO tt_epit.
    ENDIF.
     wa_epit-pgi_flag = c_x.
     MODIFY   tt_epit FROM wa_epit TRANSPORTING pgi_flag WHERE epi_id = wa_worklist-epi_id AND del_no = wa_created-document_numb .
     UPDATE zsd_dt_epit SET pgi_flag = 'X' WHERE epi_id = wa_worklist-epi_id AND del_no = wa_created-document_numb .
     IF  sy-subrc EQ 0.
     ENDIF.
  ENDIF.

HI,
Please refer this
To perform Post goods issue
    PERFORM OPEN_GROUP.
    PERFORM BDC_DYNPRO      USING 'SAPMV50A' '4004'.
    PERFORM BDC_FIELD       USING 'BDC_CURSOR'
                                  'LIKP-VBELN'.
    PERFORM BDC_FIELD       USING 'BDC_OKCODE'
                                  '=WABU_T'.
    PERFORM BDC_FIELD       USING 'LIKP-VBELN' DELIVERY.
                             '84000064'.
    PERFORM BDC_TRANSACTION USING 'VL02N'.
    PERFORM CLOSE_GROUP.
    CLEAR : DELIVERY,
            T_BSITEM,
            T_BSICTL.
  ENDIF.
ENDFORM.                    " DELIVERY

Similar Messages

  • Creation of Material using BDC Session method & global class

    Hi
    Creation of Material using BDC Session method & global class by using oops.
    can anyone plz help me out

    Hi,
    it looks like it's not possible to call this BAPI wihtout material number. Here is a quote from BAPI documentation.
    When creating material master data, you must transfer the material
    number, the material type, and the industry sector to the method. You
    must also enter a material description and its language.
    Cheers

  • Problem with uploading data from excel using BDC for tcode f-02

    Hi All,
    I am uploading data from excel using BDC for tcode f-02. The problem here is, while recording, the values of some fields are recording twice. I dont know why it's happening so. But if I run my abap program, I have to give those fields twice in my excel sheet. Otherwise data does not upload. But it is not the feasible way. We must give those fields once in excel. Please tell me, how I can solve the issue.
    With regards,
    Rosaline.

    Hi,
      in BDC each and every action is recording. If your press enter in same screen that also recorded once aging may be this is your case repeating field values will appear. we can solve the problem for repeat fields like below.
    suppose in your excel having repeated field X1 X2 X3 the X2 contains repeated field X3 means delete the X3 field.
    Now In your itab having X1 and X2 fields. While in the LOOP the ITAB pass the X2 field to repeated the fields.
    LOOP at ITAB to WA.
    CLEAR bdcdata_wa.
    bdcdata_wa-fnam = 'BDC_CURSOR'.
    bdcdata_wa-fval = 'RM08M-EBELN'.
    APPEND bdcdata_wa TO bdcdata_tab.
    CLEAR bdcdata_wa.
    bdcdata_wa-fnam = 'INVFO-BLDAT'.
    bdcdata_wa-fval = wa-X2." 1st time pass the X2 fields
    APPEND bdcdata_wa TO bdcdata_tab.
    CLEAR bdcdata_wa.
    bdcdata_wa-fnam = 'INVFO-BLDAT'.
    bdcdata_wa-fval = wa-X2." pass the same value to repeated field
    APPEND bdcdata_wa TO bdcdata_tab.
    Endloop.
    Hope you can understand.
    Regards,
    Dhina..

  • Post the lease rental charges for oprating lease asset using  bdc  for f-02

    hi any can send me the programed for t code f-02
    for post the lease rental charges for operating lease asset using  bdc  for f-02
    This is not a place where you can get your entire work done by others. Please put some effort from your side before turning to the forums for help. Thread locked.
    Locked by: kishan P on Aug 24, 2010 5:47 PM

    hi any can send me the programed for t code f-02
    for post the lease rental charges for operating lease asset using  bdc  for f-02
    This is not a place where you can get your entire work done by others. Please put some effort from your side before turning to the forums for help. Thread locked.
    Locked by: kishan P on Aug 24, 2010 5:47 PM

  • Hi, I need help my computer is not starting up at all, nothing happening when I press the button on/off. The battery charger is working as using it for another laptop. Not sure what to do. Anyone have any idea? many thanks

    Hi, I need help my computer is not starting up at all, nothing happening when I press the button on/off. The battery charger is working as using it for another laptop. Not sure what to do. Anyone have any idea? many thanks

    You could try a SMC reset:
    http://support.apple.com/kb/HT3964
    If no change, do what Allan advises.
    Caio.

  • I'm Writing from singapore. Can i purchse Apple tv from Apple store and use it in singapore. u will be only using it for the airplay feature. not keen in the movie or song download. just air play will do.. is it possible? apple TV is not sold in singapore

    I'm Writing from singapore. Can i purchse Apple tv from Apple store and use it in singapore. i will be only using it for the airplay feature.
    not keen in the movie or song download. just air play will do.. is it possible? anyway apple TV is not sold in singapore.
    Please revert
    thank you
    Vejan!

    You may or may not already have your network set up correctly, it's just that I can't tell from what you have said.
    I have a main router provided by my ISP, I have several other Airport Extremes and Airport expresses connected by Ethernet, all set up to bridge the network created by the main router.
    Each maker has their own settings, but bridging should be reasonably obvious. In simple terms my main router distributes IP addresses to all devices, the Airports bridge that network by passing these addresses to the devices from the main router. A base station that isn't in bridging mode will distribute its own addresses to the devices connected to it.
    I don't really follow your next point.
    instruction for configuration vary from manufacturer to manufacturer, the best course of action here is to refer to the manual. If everything is set up properly the addresses of everything on your network will have identical sets of numbers for the first 3 of 4 groups of numbers that make up an address, the last set must always be different. I think the part you are referring to with your DD-WRT is the option to have Ethernet and wifi bridged or not.
    Some routers may be easier to configure than others, but generally speaking they should all work with the Apple TV. 5Ghz is less likely to suffer interference but it is much more likely to be blocked by solid objects, it may or may not be an advantage.

  • How do I know WinRM uses Kerberos for authentication, and does not fall-back to NTLM?

    Hi,
    How do I know WinRM uses Kerberos for authentication, and does not fall-back to NTLM?
    /SaiTech

    Hi SaiTech,
    Kerberos will be selected by default in an AD domain, The default (assuming the client is in a domain, and is not connecting to itself via 127.0.0.1 or ::1 addresses) is to use Kerberos authentication, and not to fall back to NTLM.
    Please also Note that you may have to take some other steps as well to get non-Kerberos authentication working.  Specifically, you'd have to set up an HTTPS listener on the remote host, or modify the client's TrustedHosts list.
    Refer to:
    WINRM kerberos & Negotiate
    Authentication for Remote Connections
    In addition, you can also use Network Monitor to check the authentication method.
    If there is anything else regarding this issue, please feel free to post back.
    If you have any feedback on our support, please click here.
    Best Regards,
    Anna Wang
    TechNet Community Support
    Please remember to mark the replies as answers if they help and unmark them if they provide no help. If you have feedback for TechNet Support, contact [email protected]

  • Creation of PO using BDC with ME21N - Urgent

    Hi All,
    My requirement is to create a Purchase Order using BDC. I'm using ME21N for BDC. I did recording and using that recording I wrote a program for BDC. BDC table is populated correctly, but while calling ME21N using call transaction, program is cuming back to the selection screen, without creating PO. And sy-subrc value after call transaction is '0'. Please let me know the problem.
    Thanks in Advance.
    Siva Sankar.

    Hi,
    Put a break point after the call transaction statement(i.e, put break point on sy-subrc check)
    and then check the message table.
    if call transaction is suceessfull u will find a success messages in the I_messages table.
    Regards,
    Sriram

  • Problem with OPERATION TEXT(LTXA1) uploading using BDC For C202 Transaction

    Hi Experts,
    Im presently doing a BDC for the trransaction C202 (Change Master Recipe),my task was to upload the 'OPERATION TEXT' field PLPOD-LTXA1 which is actually Long text to an existing master recipe from a flat file during updation of the 'OPERATION TEXT the number of lines i was able to were 34 which we number lines on the displayed page and while updating the 35th line using the concept of bdc table control it is failing to insert the update text.
    I used all the ok codes but failed to update more than 34 lines.So,can someone tell me how to update the longtext beyound it.
    This is the Screenshot of my problem:
    [BDC_C202_error|http://www.freeimagehosting.net/uploads/79af6bac49.jpg]
    Thanx in advance.

    Hi,
    There is a better way of doing the long text upload in SAP. In your BDC, if I change the text editor, the BDC will not work.
    Hence ,
    Use function module " Save_Text" to update long texts in SAP.
    Please check its FM documentation or perform a search for this FM in SDN for more clarity.
    Write back in case you face further issues.
    Regards,
    Rijuraj
    Edited by: Rijuraj Raju on Sep 10, 2010 3:05 PM

  • Flat  file to upload data using BDC for transaction MM01

    Hi
    I am trying to update data using bdc code has been attached below using a txt file.
    It is updating the first set of data into the table mara ,but  for the rest it is not
    All the data from txt file has being loaded to internal table , but the problem is it does not gets updated from internal table to the database .
    Only the first set of data has been loaded ,<u><b> rest of the data is not loaded</b></u>
    <u><b>content of txt file</b></u>
    zsc     zsc     kg     
    zsv     zsv     kg     
    zsb     zsb     kg
    <u><b>Actual code</b></u>
    report ZMAT_UPLOAD
           no standard page heading line-size 255.
    types declaration..........................................................................
    types : begin of t_mat,
       matnr(20),
       desc(50),
       uom(5),
    end of t_mat.
    internal table and workarea declaration.......................................
    data : i_mat type table of t_mat.
    data : wa_mat type t_mat.
    include bdcrecx1.
    start-of-selection.
    moving the flat file content to internal table................................
    CALL FUNCTION 'UPLOAD'
         EXPORTING
             FILETYPE   = 'DAT'
         TABLES
             data_tab   = i_mat.
    IF sy-subrc <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    perform open_group.
    loop at i_mat into wa_mat.
    perform bdc_dynpro      using 'SAPLMGMM' '0060'.
    perform bdc_field       using 'BDC_CURSOR'
                                       'RMMG1-MATNR'.
    perform bdc_field       using 'BDC_OKCODE'
                                        '=AUSW'.
    perform bdc_field       using 'RMMG1-MATNR'
                                        wa_mat-matnr.
    perform bdc_field       using 'RMMG1-MBRSH'
                                        'P'.
    perform bdc_field       using 'RMMG1-MTART'
                                        'ZOH'.
    perform bdc_dynpro   using 'SAPLMGMM' '0070'.
    perform bdc_field       using 'BDC_CURSOR'
                                        'MSICHTAUSW-DYTXT(01)'.
    perform bdc_field       using 'BDC_OKCODE'
                                        '=ENTR'.
    perform bdc_field       using 'MSICHTAUSW-KZSEL(01)'
                                        'X'.
    perform bdc_dynpro   using 'SAPLMGMM' '4004'.
    perform bdc_field       using 'BDC_OKCODE'
                                        '=BU'.
    perform bdc_field       using 'MAKT-MAKTX'
                                        wa_mat-desc.
    perform bdc_field       using 'BDC_CURSOR'
                                        'MARA-MEINS'.
    perform bdc_field       using 'MARA-MEINS'
                                        wa_mat-uom.
    perform bdc_field       using 'MARA-MTPOS_MARA'
                                        'NORM'.
    perform bdc_transaction using 'MM01'.
    endloop.
    Perform close_group.

    Hi Sumant,
    just concentrate on bold one
    report ZMAT_UPLOAD
    no standard page heading line-size 255.
    types declaration..........................................................................
    <b>
    data : begin of t_mat occurs 0,
    matnr(20),
    desc(50),
    uom(5),
    end of t_mat.</b>
    internal table and workarea declaration.......................................
    <b>*data : i_mat type table of t_mat.
    *data : wa_mat type t_mat.</b>
    include bdcrecx1.
    start-of-selection.
    moving the flat file content to internal table................................
    CALL FUNCTION 'UPLOAD'
    EXPORTING
    FILETYPE = 'DAT'
    TABLES
    <b>data_tab = i_mat.---> t_mat.</b>
    IF sy-subrc <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    perform open_group.
    <b>loop at i_mat into wa_mat.------>loop at t_mat.</b>
    perform bdc_dynpro using 'SAPLMGMM' '0060'.
    perform bdc_field using 'BDC_CURSOR'
    'RMMG1-MATNR'.
    perform bdc_field using 'BDC_OKCODE'
    '=AUSW'.
    perform bdc_field using 'RMMG1-MATNR'
    <b>wa_mat-matnr.---->t_mat-matnr(change in this for ur wa to t_mat.</b>
    perform bdc_field using 'RMMG1-MBRSH'
    'P'.
    perform bdc_field using 'RMMG1-MTART'
    'ZOH'.
    perform bdc_dynpro using 'SAPLMGMM' '0070'.
    perform bdc_field using 'BDC_CURSOR'
    'MSICHTAUSW-DYTXT(01)'.
    perform bdc_field using 'BDC_OKCODE'
    '=ENTR'.
    perform bdc_field using 'MSICHTAUSW-KZSEL(01)'
    'X'.
    perform bdc_dynpro using 'SAPLMGMM' '4004'.
    perform bdc_field using 'BDC_OKCODE'
    '=BU'.
    perform bdc_field using 'MAKT-MAKTX'
    wa_mat-desc.
    perform bdc_field using 'BDC_CURSOR'
    'MARA-MEINS'.
    perform bdc_field using 'MARA-MEINS'
    wa_mat-uom.
    perform bdc_field using 'MARA-MTPOS_MARA'
    'NORM'.
    perform bdc_transaction using 'MM01'.
    endloop.
    Perform close_group.
    Reward points for helpful answers.
    Thanks
    Naveen khan
    Message was edited by:
            Pattan Naveen
    Message was edited by:
            Pattan Naveen

  • Posting More than 900 lines not allowing uploading using BDC for FB60

    Hi,
    When i am upload vendor invoices with  More than 900 lineitems using BDC program it is giving the fallowing error .
    1          You are entering line item 900 , a maximum of 999 line items are defined
    As per i know it will allow 999 line items for one document posting . But i am getting error when i am posting more than  900.
    If any body know the solution please share with me .
    Thanks
    SriHari

    I vaguely remember that SAP reserves lines for automatically created items e.g. for taxes, you might have run into that limit. Check in that direction with a functional expert, the limit might be configurable.
    Thomas
    Edit: now I did what you could have done and checked the where-used-list for message F5 138, the 900 is hard coded, and it is just a warning, seemingly to alert the user of the brick wall he is about to hit very soon.

  • How to insert more than 12 items using BDC for MB1C

    Hi,
    When we use LSMW for data transfer of MB1C transaction, more than 12 items can be  inserted in a document.
    But using BDC only 12 and below is possible, if the flat file system has more that 12 item, then the document is not created.
    How to insert more than 12 item in a document.
    Regards

    Hi Gow,
    I have uploaded the MB1C through a BDC and it is working fine for n no of items.
    Here is the code. May be this will be of your help.
    *& Report  ZMB1C
    report ZMB1C
           no standard page heading line-size 255.
    type-pools : slis.
    tables : t100.
    data: begin of record,
            MATNR(018),
            ERFMG(017),
            EXBWR(016),
          end of record.
    data : itab like table of record with header line.
    data : w_bdcdata type bdcdata.
    data : t_bdcdata type standard table of bdcdata initial size 1.
    data : messtab type standard table of bdcmsgcoll with header line.
    data : mstring(300).
    data : vf_index type i,
           no_lines type i,
           count type i value 0.
    data : v_bldat(20),
           v_budat(20).
    *Excel Sheet Data Upload Details
    data : vf_start_col type i value '1',      "start column
           vf_start_row type i value '2',      "start row
           vf_end_col   type i value '100',    "maximum column
           vf_end_row   type i value '10000'.  "maximum row
    */ Internal Table For Excel Data
    data : it_excel type  kcde_cells occurs 0 with header line.
    */ Field symbol
    field-symbols : <fs>.
    data : begin of it_messtab occurs 0,
           plant(10) type c,
           status(10) type c,
           message(90) type c,
           end of it_messtab.
    *Data for ALV display
    data : wa_fcat type slis_fieldcat_alv,
           colcnt type i.
    data : it_fieldcat type slis_t_fieldcat_alv,
           i_events type slis_t_event.
    data : l_title type sychar70.
    data : l_repid like sy-repid.
    * Selction Screen
    selection-screen begin of block b1 with frame title text-000.
    parameters : p_file like ibipparms-path obligatory,
                 p_mode like ctu_params-dismode default 'A'.
    selection-screen end of block b1.
    selection-screen begin of block b2 with frame title text-001.
    parameters : p_bldat like MKPF-BLDAT obligatory,
                 p_budat like MKPF-BUDAT obligatory,
                 p_bwart like RM07M-BWARTWA obligatory,
                 p_werks like RM07M-WERKS obligatory,
                 p_lgort like RM07M-LGORT obligatory.
    selection-screen end of block b2.
    * At Selction Screen
    at selection-screen on value-request for p_file.
      call function 'F4_FILENAME'
        EXPORTING
          program_name  = syst-cprog
          dynpro_number = syst-dynnr
          field_name    = ''
        IMPORTING
          file_name     = p_file.
    *Start of Selection Event
    start-of-selection.
      call function 'KCD_EXCEL_OLE_TO_INT_CONVERT'
        EXPORTING
          filename                = p_file
          i_begin_col             = vf_start_col
          i_begin_row             = vf_start_row
          i_end_col               = vf_end_col
          i_end_row               = vf_end_row
        TABLES
          intern                  = it_excel
        EXCEPTIONS
          inconsistent_parameters = 1
          upload_ole              = 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.
      if it_excel[] is initial.
        MESSAGE I000(ZCL_TCSABAP).
      else.
        sort it_excel by row col.
        loop at it_excel.
          move : it_excel-col to vf_index.
          assign component vf_index of structure itab to <fs>.
          move : it_excel-value to <fs>.
          at end of row.
            append itab.
            clear itab.
          endat.
        endloop.
      endif.
      if not itab[] is initial.
        DESCRIBE TABLE itab LINES no_lines.
        clear messtab.
        refresh messtab.
        CONCATENATE p_bldat+6(2) '.' p_bldat+4(2) '.' p_bldat(4) into v_bldat.
        CONCATENATE p_budat+6(2) '.' p_budat+4(2) '.' p_budat(4) into v_budat.
        perform map_rec.
        call transaction 'MB1C' using t_bdcdata mode p_mode update 'A'
        messages into messtab .
        clear t_bdcdata.
        refresh t_bdcdata.
        loop at messtab where msgtyp = 'E' or msgtyp = 'S' .
          select single * from t100 where sprsl = messtab-msgspra
                                    and   arbgb = messtab-msgid
                                    and   msgnr = messtab-msgnr.
          if sy-subrc = 0.
            mstring = t100-text.
            if mstring cs '&1'.
              replace '&1' with messtab-msgv1 into mstring.
              replace '&2' with messtab-msgv2 into mstring.
              replace '&3' with messtab-msgv3 into mstring.
              replace '&4' with messtab-msgv4 into mstring.
            else.
              replace '&' with messtab-msgv1 into mstring.
              replace '&' with messtab-msgv2 into mstring.
              replace '&' with messtab-msgv3 into mstring.
              replace '&' with messtab-msgv4 into mstring.
            endif.
            condense mstring.
            it_messtab-message = mstring(300).
            it_messtab-plant = p_werks.
            if messtab-msgtyp = 'E'.
              it_messtab-status = 'Error'.
            else.
              it_messtab-status = 'Success'.
            endif.
            append it_messtab.
            clear it_messtab.
          endif.
        endloop. "messtab
        if not it_messtab[] is initial.
          perform buildcatalog.
          perform display.
        endif.
      endif.
    *&      Form  Map_Rec
    *       text
    form  map_rec.
      perform bdc_dynpro      using 'SAPMM07M' '0400'.
      perform bdc_field       using 'BDC_CURSOR'
                                    'RM07M-WVERS3'.
      perform bdc_field       using 'BDC_OKCODE'
                                    'NPE'.
      perform bdc_field       using 'MKPF-BLDAT'
                                    v_bldat.
      perform bdc_field       using 'MKPF-BUDAT'
                                    v_budat.
      perform bdc_field       using 'RM07M-BWARTWA'
                                    p_bwart.
      perform bdc_field       using 'RM07M-WERKS'
                                    p_werks.
      perform bdc_field       using 'RM07M-LGORT'
                                    p_lgort.
      perform bdc_field       using 'XFULL'
      perform bdc_field       using 'RM07M-XNAPR'
                                    'X'.
      perform bdc_field       using 'RM07M-WVERS2'
      perform bdc_field       using 'RM07M-WVERS3'
                                    'X'.
      loop at itab.
        count = count + 1.
        perform bdc_dynpro      using 'SAPMM07M' '0410'.
        perform bdc_field       using 'BDC_CURSOR'
                                      'MSEG-EXBWR'.
        if count <> no_lines.
          perform bdc_field       using 'BDC_OKCODE'
                                        '=NPE'.
        elseif count = no_lines.
          perform bdc_field       using 'BDC_OKCODE'
                                        '=BU'.
        endif.
        perform bdc_field       using 'MSEG-MATNR'
                                      itab-MATNR.
        perform bdc_field       using 'MSEG-ERFMG'
                                      itab-ERFMG.
        perform bdc_field       using 'MSEG-EXBWR'
                                      itab-EXBWR.
      endloop. "itab
    endform. "Map_Rec
    **      Form  BDC_DYNPRO
    form bdc_dynpro using program dynpro.
      clear w_bdcdata.
      w_bdcdata-program  = program.
      w_bdcdata-dynpro   = dynpro.
      w_bdcdata-dynbegin = 'X'.
      append w_bdcdata to t_bdcdata.
    endform.                    "bdc_dynpro
    **      Form  BDC_FIELD
    form bdc_field using fnam fval.
      if fval <> space.
        clear w_bdcdata.
        w_bdcdata-fnam = fnam.
        w_bdcdata-fval = fval.
        append w_bdcdata to t_bdcdata.
      else.
        clear w_bdcdata.
        w_bdcdata-fnam = fnam.
        w_bdcdata-fval = fval.
        append w_bdcdata to t_bdcdata.
      endif.
    endform.                    "bdc_field
    *       FORM buildcatalog                                             *
    form buildcatalog.
      clear wa_fcat.
      clear it_fieldcat.
      colcnt = colcnt + 1.
      wa_fcat-col_pos      = colcnt.
      wa_fcat-fieldname    = 'PLANT'.
      wa_fcat-tabname      = it_messtab.
      wa_fcat-seltext_l    = 'PLANT'.
      wa_fcat-key          = 'X'.
      wa_fcat-outputlen  = '10'.
      append wa_fcat to it_fieldcat.
      clear wa_fcat.
      colcnt = colcnt + 1.
      wa_fcat-col_pos      = colcnt.
      wa_fcat-fieldname    = 'STATUS'.
      wa_fcat-tabname      = it_messtab.
      wa_fcat-seltext_l    = 'STATUS'.
      wa_fcat-outputlen  = '10'.
      append wa_fcat to it_fieldcat.
      clear wa_fcat.
      colcnt = colcnt + 1.
      wa_fcat-col_pos      = colcnt.
      wa_fcat-fieldname    = 'MESSAGE'.
      wa_fcat-tabname      = it_messtab.
      wa_fcat-seltext_l    = 'Message'.
      wa_fcat-outputlen  = '90'.
      append wa_fcat to it_fieldcat.
    endform.                    "buildcatalog
    *       FORM display                                                  *
    form display.
      l_title = text-002.
      l_repid = sy-repid.
      call function 'REUSE_ALV_GRID_DISPLAY'
        EXPORTING
          i_callback_program = l_repid
          i_grid_title       = l_title
          it_fieldcat        = it_fieldcat
          it_events          = i_events[]
        TABLES
          t_outtab           = it_messtab
        EXCEPTIONS
          program_error      = 1
          others             = 2.
      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.                    "display
    Regards,
    Amit

  • Profile Creation in BW using BDC

    Hi,
    Is it possible to create profiles in BW using BDC's?
    Thanks,
    Suja

    Thanks a lot.
    Have you tried this?
    I did everything that is mentioned in the document. I can also see the profile generated successfully. But when I run the report is doesnt apply the necessary restriction.
    I created a cube which has material,customer,invoice,date and 2 measures.I restricted Material to a single value as explained in the document.In Su01 it shows the correct values.But the query still runs for all the material values. I have omitted the heirarchy part of this document.Would that be the reason?
    Any input on this would be veryh helpful. Thanks again.
    Suja

  • Different screens shown when using BDC for Transaction XK03

    Hello Forum,
    Please provide a soultion for the below problem .
    When i open transaction XK03 (with 4 check boxes of general Data ticked )it is ok.
    When i call transaction XK03 from my program (by sending the check box parameters ticked)- the scren shown is different .
    (I used BDC to set the checkboxes)
    Sample code for testing that i write to call XK03 is -
    DATA: ls_bdc_comp  TYPE bdcdata,                   "workarea for BDC recording of XK03
            lt_bdc_comp  TYPE STANDARD TABLE OF bdcdata. "table for BDC recording of MK03
      CLEAR: ls_bdc_comp .
      REFRESH lt_bdc_comp.
      CLEAR ls_bdc_comp.
      ls_bdc_comp-program = 'SAPMF02K'.
      ls_bdc_comp-dynpro = '0101'.
      ls_bdc_comp-dynbegin = wc_x.
      APPEND ls_bdc_comp TO lt_bdc_comp.
      CLEAR ls_bdc_comp.
      ls_bdc_comp-fnam = 'BDC_OKCODE'.
      ls_bdc_comp-fval = '/00'.
      APPEND ls_bdc_comp TO lt_bdc_comp.
      CLEAR ls_bdc_comp.
      ls_bdc_comp-fnam = 'RF02K-LIFNR'.
      ls_bdc_comp-fval = 'S000819001'. "Vendor
      APPEND ls_bdc_comp TO lt_bdc_comp.
      CLEAR ls_bdc_comp.
      ls_bdc_comp-fnam = 'RF02K-D0110'.  "Address
      ls_bdc_comp-fval = 'X'.
      APPEND ls_bdc_comp TO lt_bdc_comp.
      CLEAR ls_bdc_comp.
      ls_bdc_comp-fnam = 'RF02K-D0120'. "Control
      ls_bdc_comp-fval = 'X'.
      APPEND ls_bdc_comp TO lt_bdc_comp.
      CLEAR ls_bdc_comp.
      ls_bdc_comp-fnam = 'RF02K-D0130'. "Payment transactions
      ls_bdc_comp-fval = 'X'.
      APPEND ls_bdc_comp TO lt_bdc_comp.
      CLEAR ls_bdc_comp.
      ls_bdc_comp-fnam = 'WRF02K-D0380'. "contact person
      ls_bdc_comp-fval = 'X'.
      APPEND ls_bdc_comp TO lt_bdc_comp.
      CALL TRANSACTION 'XK03'
           USING lt_bdc_comp.
           MODE 'E'.
    Regards
    Lovleen
    Moderator Message: Please use proper subject lines while posting your questions.
    Edited by: Suhas Saha on Jul 22, 2011 3:48 PM

    Hi,
    You can try with below code,
    DATA: ls_bdc_comp TYPE bdcdata, "workarea for BDC recording of XK03
    lt_bdc_comp TYPE STANDARD TABLE OF bdcdata. "table for BDC recording of MK03
    CLEAR: ls_bdc_comp .
    REFRESH lt_bdc_comp.
    CLEAR ls_bdc_comp.
    ls_bdc_comp-program = 'SAPMF02K'.
    ls_bdc_comp-dynpro = '0101'.
    ls_bdc_comp-dynbegin = 'X'.
    APPEND ls_bdc_comp TO lt_bdc_comp.
    CLEAR ls_bdc_comp.
    ls_bdc_comp-fnam = 'BDC_OKCODE'.
    ls_bdc_comp-fval = '/00'.
    APPEND ls_bdc_comp TO lt_bdc_comp.
    CLEAR ls_bdc_comp.
    ls_bdc_comp-fnam = 'RF02K-LIFNR'.
    ls_bdc_comp-fval = 'S000819001'. "Vendor
    APPEND ls_bdc_comp TO lt_bdc_comp.
    CLEAR ls_bdc_comp.
    ls_bdc_comp-fnam = 'RF02K-D0110'. "Address
    ls_bdc_comp-fval = 'X'.
    APPEND ls_bdc_comp TO lt_bdc_comp.
    CLEAR ls_bdc_comp.
    ls_bdc_comp-fnam = 'RF02K-D0120'. "Control
    ls_bdc_comp-fval = 'X'.
    APPEND ls_bdc_comp TO lt_bdc_comp.
    CLEAR ls_bdc_comp.
    ls_bdc_comp-fnam = 'RF02K-D0130'. "Payment transactions
    ls_bdc_comp-fval = 'X'.
    APPEND ls_bdc_comp TO lt_bdc_comp.
    CLEAR ls_bdc_comp.
    ls_bdc_comp-fnam = 'WRF02K-D0380'. "contact person
    ls_bdc_comp-fval = 'X'.
    APPEND ls_bdc_comp TO lt_bdc_comp.
    ls_bdc_comp-fnam = 'USE_ZAV'. "contact person
    ls_bdc_comp-fval = 'X'.
    APPEND ls_bdc_comp TO lt_bdc_comp.
    CALL TRANSACTION 'XK03'
    USING lt_bdc_comp
    MODE 'E'.
    It will also take you to some other screen but up to some extend you will able to see same kind of data.

  • How to revert the data that is loaded using BDC for transaction PA30

    Hi All,
    We had loaded the data in SAP using BDC-Session Unfortunately.
    Now we want to delete all the data which is loaded usong these sessions.
    Please can anyone know the procedure to do so.(May be using LSMW)
    This is the test environment.
    This is the HR Data.
    Transaction we used is PA30.
    Thank you,
    Edited by: Kumar B on Sep 16, 2009 6:55 PM

    Sorry All for the late response.
    Thanks Swathi ..I thought in same manner.
    But we used the LSMW,It deleted the records in the exact fashion we need.
    It was a nice experience.
    Use T-code SE38 run the report RPUDELPN and pass the pernr entire data will delete. as it is a test client then go to NUMKR Feature reset it and upload the correct data again.
    I think that would not have worked for us as it deletes all the employee records.
    Might be dangerous too
    If it is has standard fast entry screen then use pa70 for mass deletion
    Apart from deletion,Also we need to delimit the previous record.
    Thank you All

Maybe you are looking for

  • How to execute vb script with out using Remote manager in oim 11g r2

    Hi Currently, i have a requirement to execute  vb script (present on a remote machine in which connector server is installed) from oim machine while using Exchange connector (11.1.1.6). This can be achieved by using remote manager,but i dont want to

  • My ipod touch will not show up under my devices  wlp!!!

    My son has an ipod Nano, and recently received an ipod touch.  The Nano will appear under devices in itunes, but the ipo touch will not.  I have tried everything, I am ready to throw it out the window.  Any suggestions from anyone?

  • Issue regarding Automatic payment program

    Hi, I have created a payment proposal and while running payment program, progarm is strucked with Payment Run has been realesed 10.07.08 09:30:44.  Please some one can help me why this is message is comming and how to fix it and carry out my payment

  • Can i use an OTG for my iphone 4s?

    CAn i use an OTG on my iphone for usin flash drive..

  • Clear Box with White Outline?

    On my MacBook Pro, a clear/transparent box will occasionaly appear on top of all of my other applications and prevents me from doing anything. I've never seen this before and I can't seem to get rid of it without restarting my computer. Is this somet