ABOUT ME

-

Today
-
Yesterday
-
Total
-
  • BDC for dummies
    SAP FI 2008. 2. 23. 15:55
    반응형

    New record

    Program

    Make program name

    Then

    Input name again

    Source code

    Input ZFI into package field

    Enter

    Make CR

    Source code

    1) insert occur 0

     

    * which describes the field.

    * If you don't have a data element use the

    * comment without a data element name

    * 3.) The second line shows the fieldname of the

    * structure, the fieldname must consist of

    * a fieldname and optional the character '_' and

    * three numbers and the field length in brackets

    * 4.) Each field must be type C.

    *

    *** Generated data section with specific formatting - DO NOT CHANGE ***

    data: begin of record OCCURS 0,

    * data element: BLDAT

    BLDAT_001(010),

    * data element: BLART

    BLART_002(002),

    * data element: BUKRS

    BUKRS_003(004),

    * data element: BUDAT

    .....

     

    2) insert “*”

    Insert some code

     

    ......

    * data element: FMORE

    FMORE_022(001),

    * data element: RMVCT

    RMVCT_023(003),

    end of record.

    *** End generated data section ***

    start-of-selection.

    *perform open_dataset using dataset.

    *perform open_group.

    CALL FUNCTION 'UPLOAD'

    EXPORTING

    FILENAME = 'C:\ACCNT.TXT'

    FILETYPE = 'DAT'

    TABLES

    DATA_TAB = RECORD.

    *do.

    LOOP AT RECORD.

    *read dataset dataset into record.

    *if sy-subrc <> 0. exit. endif.

    perform bdc_dynpro using 'SAPMF05A' '0100'.

    perform bdc_field using 'BDC_CURSOR'

    'RF05A-NEWKO'.

    perform bdc_field using 'BDC_OKCODE'

    '/00'.

    ....

     

    3)

    Insert “*”

    Insert some code

     

    perform bdc_field using 'DKACB-FMORE'

    record-FMORE_022.

    perform bdc_dynpro using 'SAPLKACB' '0002'.

    perform bdc_field using 'BDC_CURSOR'

    'COBL-RMVCT'.

    perform bdc_field using 'BDC_OKCODE'

    '=ENTE'.

    perform bdc_field using 'COBL-RMVCT'

    record-RMVCT_023.

    perform bdc_transaction using 'FB01'.

    ENDLOOP.

    *enddo.

    *perform close_group.

    *perform close_dataset using dataset.

     

    SAVE

    active using 7th icon

     

    Prepare upload data

    End

     

    I'm not developer, just FI module solution consultant.

    I don't know ABAP logic.

    when u can't receive help from developer,

    You can make this BDC recording program by yourself.

    In my case, I can't receive any hand from developer,

    so I found this BDC method for uploading mass data

    like many accounting documents or master data.

     

    *Preconditions

    You should have development key for yor SAP connection ID.

     

    If you don't understand beginer's bdc guide,

    please let me know via commet, I can support u, maybe..

     

    http://hksap.tistory.com

    http://www.sapblog.kr

    'SAP FI' 카테고리의 다른 글

    FI/CO T-code List  (0) 2008.02.29
    전표작성시 세금코드 필드관련  (0) 2008.02.14
    현지통화문제접근  (0) 2008.02.02

    댓글

회계와 IT의 교차점.. as-is SAP FI Con, to-be indirect heavy investor.