BDC session : Error records
I used a Bapi function module. In that i handled the error message and display as output in alv format but they changed the requirement like
it has to create a session with those error recrods. is it possible?
Please help
Thank you
Hi Pydi Reddy,
Session to be created with error records? I couldn't understand, why they want to create a session with error records? do they mean that you have to create a BDC for the same T.Code and once BAPI fails to update those records then BDC should be used for those error records?
Ask them what exactly they mean to schedule a session with error records.
Thanks & Regards,
Faheem.
Similar Messages
-
BDC session error handling for IW41 transaction
Hi,
When the order confirmation is done by BDC session program, it is executed without any error. But if we do the same process manually, it is showing the error message as 'Posting period is Locked for 001 2012'. My question here is why this is not happening when it is executed through bdc session program.
Anyone can help us?
Thanks,
GunaIt is difficult to believe that you would get good results from background BDC process and error in foreground using same transaction and exactly the same data. Beyond that, why is month 1 of the current year locked? Are you absolutely sure that:
BDC works correctly? maybe does NOT and the errors have been missed or ignored?
Data is precisely the same for both BDC sessions?
Same transaction is called?
Sounds silly perhaps, but I have to believe that something is very different between the two sessions. -
How to show Session Error Records to End Users
Hi all,
I had to populate data using SESSION Method...
I have 1000 records, out of which 750 records where updated correctly but i got 250 error records in it.
i know that error records are stored in Error log/ INCORRECT SESSION in SM35.
Now i want to modify these errounous records and repopulate them.
Questions.
1) We click on ANALYSE in SM35 to determine which sreen and value produced the error. if we have small data we can correct them interactively there only. But for 250 records how we have to correct them and upload 250 errors records.
2) Can we download those error records into a flatfile.
3) Is there any other method to handle such situation.
Regards
SurendarVijay,
I got your piece of code.... Its looking really good.
Here my point is once that first validation is done i am doing exit. That means total process stopped and cotrol comes out of the program. so how can this
IF W_FLAG_ERROR = X. DISPLAY THE ERROR MESSAGE to the user
will be executed ...............
and
bu writing it on the report list or just do LEAVE-LIST PROCESSING and come back to the selection screen. ESLE. CONTINUE PROCESSING ENDIF.
I didn't fallow what u said here can u explain bit clearly plzzzzzz
Nisha.... -
BDC Session Error Handling and flat fie
Hi ,
I need two clarifications in BDC .......
1)I have to upload some data using BDC thru some tcode which contains header and line items...How can i build a flat file which contains both header and line item data for uploading.. pls explain how to differntiate header and line item in flat file
2) In Session method..while uploading some error has occured..How can i reprocess the error data, whether I need to upload it again or can I process the error data in SM35 itself.
Thanks in advance
Regards
Saravan1) When uploading data is better to ask the flat file with out headers, in case it is impossible, just read the internal table with the data from INDEX 2.
Something like,
LOOP AT IT_DATA FROM INDEX 2.
ENDOOP.
2) It is better to start the process again after checking what happened during last upload.
Bye
Gabriel p.- -
How to handle Error Records in BDC
Dear All,
I have 100 records in flat file but 10 records have error record.
Use on the BDC method, error records should be move to session and remaining process through call Transaction .
Any one help to me.
With Regards,
BaskaranHi,
Do it like this:
Loop at itab into wa.
gv_flag = 'N'.
If gv_flag = 'N'.
Perform...
wa_opts-dismode = 'N'. "for background
wa_opts-updmode ='S'.
wa_opts-defsize = 'X'.
wa_opts-nobinpt = 'X'.
Where wa_opts TYPE ctu_params.
*Call transaction
CALL TRANSACTION 'PA30' USING gi_bdcdata
OPTIONS FROM wa_opts
MESSAGES INTO gi_messtab.
IF sy-subrc EQ 0.
COMMIT WORK.
ELSE.
IF NOT gi_messtab[] IS INITIAL.
LOOP AT gi_messtab INTO wa_messtab.
IF wa_messtab-msgtyp EQ 'E' OR
wa_messtab-msgtyp EQ 'A' OR
wa_messtab-msgtyp EQ 'X' OR
wa_messtab-msgid EQ 'PBAS_SERVICE'.
CLEAR gv_msg.
CALL FUNCTION 'FORMAT_MESSAGE'
EXPORTING
id = wa_messtab-msgid
lang = sy-langu
no = wa_messtab-msgnr
v1 = wa_messtab-msgv1
v2 = wa_messtab-msgv2
v3 = wa_messtab-msgv3
v4 = wa_messtab-msgv4
IMPORTING
msg = gv_msg
EXCEPTIONS
not_found = 1
OTHERS = 2.
*In case of no error message returned by BDC
IF sy-subrc = 0.
Sending errors stating which infotypes are not updated.
gv_error_flag = 'Y'.
do th required proccesing here.
ELSE.
gv_error_flag = 'Y'.
statements.
ENDIF.
ENDIF.
CLEAR wa_messtab.
ENDLOOP.
endloop.
Regards,
Rajesh Kumar
Edited by: Rajesh Kumar on Sep 17, 2009 7:58 AM -
Bdc session submit automatically
HI
My requirement is like this..
if checkbox is checked on sel scree, then bdc session created shud be submitted automatically
otherwise not, it shud only be created.
i can do this by 'RSBDCSUB', but this prog has date on sel screen, i can submit this program with my session name
but all those sessions that are ceated on that date will be processed, but user might run my prog twice
and checks the checkbox only once, then only that time session should be processed, not any other,
sessions name will be same everytime.
how to achieve this
Regards
ManuHi,
Use Open group and Close Group perform routines and add this code it will post automatically
FORM release_bdc.
DATA:v_qid type apqi-qid.
SUBMIT rsbdcsub WITH mappe EQ p_group
WITH von EQ sy-datum
WITH bis EQ sy-datum
WITH fehler EQ '.'
EXPORTING LIST TO MEMORY
AND RETURN.
SUBMIT rsbdcsub WITH mappe EQ p_group "v_session contains the session name you have created in your program
WITH von EQ sy-datum
WITH bis EQ sy-datum
AND RETURN.
Displaying session for errors
selection for qid to display session log
SELECT SINGLE qid
INTO v_qid FROM
apqi WHERE
datatyp = 'BDC'
AND groupid = p_group
AND progid = sy-repid
AND userid = sy-uname
AND credate = sy-datum.
IF v_qid IS NOT INITIAL.
submit the program for BDC session error log
SUBMIT rsbdc_protocol
WITH session EQ p_group
WITH user EQ sy-uname
WITH queue_id EQ v_qid
AND RETURN.
ENDIF.
ENDFORM. " release_bdc
Regards,
Manesh.R -
Listing BDC session method error records
Hi ABAP'rs,
Can any one help me, how to show error records of BDC session method on the List screen.
Thanks and Regards,
Param.Hi,
goto sm35 and find the error logs.
what do you mean by list screen...do you mean in ort output ?
Regards,
pankaj singh -
Error in my BDC SESSION METHOD
Hi,
I was trying work on BDC SESSION METHOD AND MY TCODE IS XK01.
Here is my code can some one tell me where i am doing wrong becoz its not giving the output as I expected. And I am uploading a tab delimeter file.
report ZAN_BDCVENDOR
no standard page heading line-size 255.
include bdcrecx1.
DATA: I_BDCDATA LIKE BDCDATA OCCURS 0 WITH HEADER LINE.
DATA: BEGIN OF RECORD OCCURS 0,
LIFNR(016),
BURKS(004),
EKORG(004),
KTOKK(004),
AKONT(010),
FDGRV(010),
WAERS(005),
END OF RECORD.
start-of-selection.
perform open_group.
CALL FUNCTION 'GUI_UPLOAD'
EXPORTING
filename = 'C:\VENDOR.TXT'
FILETYPE = 'ASC'
tables
data_tab = RECORD
IF sy-subrc <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
LOOP AT RECORD.
perform bdc_dynpro using 'SAPMF02K' '0100'.
perform bdc_field using 'BDC_CURSOR'
'USE_ZAV'.
perform bdc_field using 'BDC_OKCODE'
'/00'.
perform bdc_field using 'RF02K-LIFNR'
'8765'.
perform bdc_field using 'RF02K-BUKRS'
'1000'.
perform bdc_field using 'RF02K-EKORG'
'1000'.
perform bdc_field using 'RF02K-KTOKK'
'0001'.
perform bdc_field using 'USE_ZAV'
'X'.
perform bdc_dynpro using 'SAPMF02K' '0210'.
perform bdc_field using 'BDC_CURSOR'
'LFB1-FDGRV'.
perform bdc_field using 'BDC_OKCODE'
'=UPDA'.
perform bdc_field using 'LFB1-AKONT'
'160000'.
perform bdc_field using 'LFB1-FDGRV'
'A1'.
perform bdc_dynpro using 'SAPMF02K' '0310'.
perform bdc_field using 'BDC_CURSOR'
'LFM1-WAERS'.
perform bdc_field using 'BDC_OKCODE'
'=UPDA'.
perform bdc_field using 'LFM1-WAERS'
'usd'.
perform bdc_transaction using 'XK01'.
ENDLOOP.
perform close_group.
CALL FUNCTION 'BDC_OPEN_GROUP'
EXPORTING
CLIENT = SY-MANDT
DEST = FILLER8
GROUP = 'SESSION1'
HOLDDATE = FILLER8
KEEP = FILLER1
USER = SY-UNAME
RECORD = FILLER1
PROG = SY-CPROG
IMPORTING
QID =
EXCEPTIONS
CLIENT_INVALID = 1
DESTINATION_INVALID = 2
GROUP_INVALID = 3
GROUP_IS_LOCKED = 4
HOLDDATE_INVALID = 5
INTERNAL_ERROR = 6
QUEUE_ERROR = 7
RUNNING = 8
SYSTEM_LOCK_ERROR = 9
USER_INVALID = 10
OTHERS = 11
IF sy-subrc <> 0.
WRITE 'ERROR IN OPEN_GROUP'.
ENDIF.
CALL FUNCTION 'BDC_INSERT'
EXPORTING
TCODE = TCODE
POST_LOCAL = NOVBLOCAL
PRINTING = NOPRINT
SIMUBATCH = ' '
CTUPARAMS = ' '
TABLES
dynprotab = I_BDCDATA
EXCEPTIONS
INTERNAL_ERROR = 1
NOT_OPEN = 2
QUEUE_ERROR = 3
TCODE_INVALID = 4
PRINTING_INVALID = 5
POSTING_INVALID = 6
OTHERS = 7
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 'BDC_CLOSE_GROUP'
EXCEPTIONS
NOT_OPEN = 1
QUEUE_ERROR = 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.
I appreciateHi,
i guess, the error is due to, u didnt pass the TCODE parameter in BDC_INSERT FM.
Try by passing it...
CALL FUNCTION 'BDC_INSERT'
EXPORTING
TCODE = TCODE*
POST_LOCAL = NOVBLOCAL
PRINTING = NOPRINT
SIMUBATCH = ' '
CTUPARAMS = ' '
TABLES
dynprotab = I_BDCDATA
EXCEPTIONS
INTERNAL_ERROR = 1
NOT_OPEN = 2
QUEUE_ERROR = 3
TCODE_INVALID = 4
PRINTING_INVALID = 5
POSTING_INVALID = 6
OTHERS = 7
Hope it works!!
Regards,
Pavan -
How to handle the errors in BDC Session method
Hi All,
I am uploading Material Master (MM01) records using BDC Session Method.my problem is when i am running the program, all the error records are going to flat file.how can i correcting the error records and after correction how can i re-process the error records.tell me with example.
i have around 70,000 records in my flat file.Hi,
I am attaching few threads.Hope these will help you.
If there are any error records in session, all those error records will get poulated in log .SM35 and after the session is completed , u can see error records which can be corrected and reprocessed again
We have the structures BDCLD and BDCLM, which will capture the log details inthe session. Firstly, sesssion should be processed. After that log will be created. Then caputure the information into an internal table using BDCLM and BDCLD.
and refer the link.
error correction in bdc session
regards
Madhu -
How to overcome view changes in bdc session method using recording ?
how to overcome view changes in bdc session method using recording ?
ex-for mm01 in recording if i selected views basic data1 and basic data2.
i seheduleded for background for after 3 days .
if any body changes views by selecting other views also.
how to overcome this with out programming ?
is there any settings ?Hi,
I am attaching few threads.Hope these will help you.
If there are any error records in session, all those error records will get poulated in log .SM35 and after the session is completed , u can see error records which can be corrected and reprocessed again
We have the structures BDCLD and BDCLM, which will capture the log details inthe session. Firstly, sesssion should be processed. After that log will be created. Then caputure the information into an internal table using BDCLM and BDCLD.
and refer the link.
error correction in bdc session
regards
Madhu -
Error in BDC session for tcode MR21
Hello all,
I have to create one BDC session program for change in valuation price.
i have following input parameter :
Plant Article Price, Dec 2 Price unit
0690 000000000906671600 00000021207 00100
the price is 212,07 a decimal sign is not included
i have created one program but its not working.its giving runtime error CONVT_NO_NUMBER
Edited by: Sujeet Mishra on Apr 22, 2009 3:07 PM
LOOP AT it_final.
*perform open_dataset using dataset.
*perform open_dataset using p_file.
perform open_group.
*do.
*read dataset dataset into record.
*if sy-subrc <> 0. exit. endif.
perform bdc_dynpro using 'SAPRCKM_MR21' '0201'.
perform bdc_field using 'BDC_CURSOR'
'MR21HEAD-BUDAT'.
perform bdc_field using 'BDC_OKCODE'
'=ENTR'.
*perform bdc_field using 'MR21HEAD-BUDAT'
record-BUDAT_001.
perform bdc_field using 'MR21HEAD-WERKS'
IT_FINAL-WERKS.
*perform bdc_field using 'MR21HEAD-SCREEN_VARIANT'
record-SCREEN_VARIANT_003.
perform bdc_dynpro using 'SAPRCKM_MR21' '0201'.
perform bdc_field using 'BDC_OKCODE'
'=ENTR'.
perform bdc_field using 'BDC_CURSOR'
'CKI_MR21_0250-NEWVALPR(01)'.
*perform bdc_field using 'MR21HEAD-SCREEN_VARIANT'
record-SCREEN_VARIANT_004.
perform bdc_field using 'CKI_MR21_0250-MATNR(01)'
IT_FINAL-MATNR.
*perform bdc_field using 'CKI_MR21_0250-BWTAR(01)'
record-BWTAR_01_006.
*perform bdc_field using 'CKI_MR21_0250-NEWVALPR(01)'
IT_FINAL-PRICE.
perform bdc_dynpro using 'SAPRCKM_MR21' '0201'.
perform bdc_field using 'BDC_OKCODE'
'=SAVE'.
perform bdc_field using 'BDC_CURSOR'
'CKI_MR21_0250-MATNR(02)'.
*perform bdc_field using 'MR21HEAD-SCREEN_VARIANT'
record-SCREEN_VARIANT_008.
perform bdc_transaction using 'MR21'.
perform bdc_dynpro using 'SAPRCKM_MR21' '0201'.
*perform bdc_field using 'BDC_CURSOR'
'MR21HEAD-BUDAT'.
perform bdc_field using 'BDC_OKCODE'
'=ENTR'.
*perform bdc_field using 'MR21HEAD-BUDAT'
record-BUDAT_009.
perform bdc_field using 'MR21HEAD-WERKS'
IT_FINAL-WERKS.
*perform bdc_field using 'MR21HEAD-SCREEN_VARIANT'
record-SCREEN_VARIANT_011.
perform bdc_dynpro using 'SAPRCKM_MR21' '0201'.
perform bdc_field using 'BDC_OKCODE'
'=ENTR'.
perform bdc_field using 'BDC_CURSOR'
'CKI_MR21_0250-NEWVALPR(01)'.
*perform bdc_field using 'MR21HEAD-SCREEN_VARIANT'
record-SCREEN_VARIANT_012.
perform bdc_field using 'CKI_MR21_0250-MATNR(01)'
IT_FINAL-MATNR.
*perform bdc_field using 'CKI_MR21_0250-BWTAR(01)'
record-BWTAR_01_014.
perform bdc_field using 'CKI_MR21_0250-NEWVALPR(01)'
IT_FINAL-PRICE.
perform bdc_dynpro using 'SAPRCKM_MR21' '0201'.
perform bdc_field using 'BDC_OKCODE'
'=SAVE'.
perform bdc_field using 'BDC_CURSOR'
'CKI_MR21_0250-MATNR(02)'.
*perform bdc_field using 'MR21HEAD-SCREEN_VARIANT'
record-SCREEN_VARIANT_016.
perform bdc_transaction using 'MR21'.
*enddo.
perform close_group.
*perform close_dataset using dataset.
*perform close_dataset using p_file.
ENDLOOP.
Edited by: Sujeet Mishra on Apr 22, 2009 3:09 PM
Edited by: Sujeet Mishra on Apr 23, 2009 5:56 AMHello
my amount field code
perform bdc_field using 'CKI_MR21_0250-NEWVALPR(01)'
IT_FINAL-NEWVALPR.
is giving dump.
my declaration are like below :
Generated data section with specific formatting - DO NOT CHANGE ***
data: begin of record,
data element: BUDAT
BUDAT_001(010),
data element: WERKS_D
WERKS_002(004),
data element: SCREEN_VARIANT
SCREEN_VARIANT_003(030),
data element: SCREEN_VARIANT
SCREEN_VARIANT_004(030),
data element: MATNR
MATNR_01_005(018),
data element: BWTAR_D
BWTAR_01_006(010),
data element: VALPR
NEWVALPR_01_007(015),
data element: SCREEN_VARIANT
SCREEN_VARIANT_008(030),
end of record.
End generated data section ***
data: begin of it_final occurs 0,
BUDAT TYPE MR21HEAD-BUDAT,
WERKS TYPE MR21HEAD-WERKS,
SCREEN_VARIANT TYPE MR21HEAD-SCREEN_VARIANT,
SCREEN_VARIANT_004 TYPE MR21HEAD-SCREEN_VARIANT,
MATNR TYPE CKI_MR21_0250-MATNR,
BWTAR TYPE CKI_MR21_0250-BWTAR,
NEWVALPR TYPE CKI_MR21_0250-NEWVALPR,
SCREEN_VARIANT_008 TYPE MR21HEAD-SCREEN_VARIANT,
end of it_final.
please guide me.
thanks,
sujeet
Edited by: Sujeet Mishra on Apr 23, 2009 12:44 PM -
Error in BDC session Insert.....
Hi All,
Guys iam running BDC pgm for MEK1 create condition records transaction and i get an error while executing through BDC_INSERT. Its an internal error with text "Error in BDC session Insert..".The text file iam using contains 26 line items for the first contract created earlier and 30 line items for the second record. My concern is it only happens for this text file with multiple or more line items.
While debugging i have observed that after the session has been created the first bdc insert goes well for the first header record and then it fails for the second record with an internal error "Error in BDC session Insert..".
Does anyone have enountered such issue before or is it related to limited number of line items in MEK1 transaction.
Any help would be appreciated.
Thanks,
Avinashreport ZSESSION1
no standard page heading line-size 255.
*include bdcrecx1.
DATA: BDCDATA LIKE BDCDATA OCCURS 0 WITH HEADER LINE .
TYPES: BEGIN OF TYP_STU,
Z_STUDID TYPE ZSTUD1-Z_STUDID,
Z_STUDNAME TYPE ZSTUD1-Z_STUDNAME,
Z_STUDAGE TYPE ZSTUD1-Z_STUDAGE,
END OF TYP_STU.
DATA: IT_STU TYPE STANDARD TABLE OF TYP_STU,
GW_STU TYPE TYP_STU,
V_PATH TYPE STRING.
PARAMETERS SUREN TYPE IBIPPARMS-PATH OBLIGATORY.
AT SELECTION-SCREEN ON VALUE-REQUEST FOR SUREN .
PERFORM GETFILE USING SUREN.
V_PATH = SUREN.
CALL FUNCTION 'GUI_UPLOAD'
EXPORTING
FILENAME = V_PATH
FILETYPE = 'ASC'
HAS_FIELD_SEPARATOR = ' '
HEADER_LENGTH = 0
READ_BY_LINE = 'X'
DAT_MODE = ' '
CODEPAGE = ' '
IGNORE_CERR = ABAP_TRUE
REPLACEMENT = '#'
CHECK_BOM = ' '
VIRUS_SCAN_PROFILE =
NO_AUTH_CHECK = ' '
IMPORTING
FILELENGTH =
HEADER =
TABLES
DATA_TAB = IT_STU
EXCEPTIONS
FILE_OPEN_ERROR = 1
FILE_READ_ERROR = 2
NO_BATCH = 3
GUI_REFUSE_FILETRANSFER = 4
INVALID_TYPE = 5
NO_AUTHORITY = 6
UNKNOWN_ERROR = 7
BAD_DATA_FORMAT = 8
HEADER_NOT_ALLOWED = 9
SEPARATOR_NOT_ALLOWED = 10
HEADER_TOO_LONG = 11
UNKNOWN_DP_ERROR = 12
ACCESS_DENIED = 13
DP_OUT_OF_MEMORY = 14
DISK_FULL = 15
DP_TIMEOUT = 16
OTHERS = 17
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 'BDC_OPEN_GROUP'
EXPORTING
CLIENT = SY-MANDT
DEST = FILLER8
GROUP = 'SESSION1'
HOLDDATE = FILLER8
KEEP = 'X'
USER = SY-UNAME
RECORD = FILLER1
PROG = SY-CPROG
DCPFM = '%'
DATFM = '%'
IMPORTING
QID =
EXCEPTIONS
CLIENT_INVALID = 1
DESTINATION_INVALID = 2
GROUP_INVALID = 3
GROUP_IS_LOCKED = 4
HOLDDATE_INVALID = 5
INTERNAL_ERROR = 6
QUEUE_ERROR = 7
RUNNING = 8
SYSTEM_LOCK_ERROR = 9
USER_INVALID = 10
OTHERS = 11
IF SY-SUBRC <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
START-OF-SELECTION.
LOOP AT IT_STU INTO GW_STU.
REFRESH BDCDATA.
*perform open_group.
perform bdc_dynpro using 'SAPMSRD0' '0102'.
perform bdc_field using 'BDC_CURSOR'
'RSRD1-TBMA_VAL'.
perform bdc_field using 'BDC_OKCODE'
'=EDIT'.
perform bdc_field using 'RSRD1-TBMA'
'X'.
perform bdc_field using 'RSRD1-TBMA_VAL'
'ZSTUD1'.
perform bdc_dynpro using 'SAPLSD41' '2200'.
perform bdc_field using 'BDC_CURSOR'
'DD02D-DDTEXT'.
perform bdc_field using 'BDC_OKCODE'
'=TDED'.
perform bdc_field using 'DD02D-DDTEXT'
'Stud details'.
perform bdc_dynpro using '/1BCDWB/DBZSTUD1' '0101'.
perform bdc_field using 'BDC_CURSOR'
'ZSTUD1-Z_STUDAGE'.
perform bdc_field using 'BDC_OKCODE'
'=SAVE'.
perform bdc_field using 'ZSTUD1-Z_STUDID'
GW_STU-Z_STUDID .
perform bdc_field using 'ZSTUD1-Z_STUDNAME'
GW_STU-Z_STUDNAME .
perform bdc_field using 'ZSTUD1-Z_STUDAGE'
GW_STU-Z_STUDAGE .
perform bdc_dynpro using '/1BCDWB/DBZSTUD1' '0101'.
perform bdc_field using 'BDC_OKCODE'
'/EBACK'.
perform bdc_field using 'BDC_CURSOR'
'ZSTUD1-Z_STUDID'.
perform bdc_dynpro using 'SAPLSD41' '2200'.
perform bdc_field using 'BDC_CURSOR'
'DD02D-DDTEXT'.
perform bdc_field using 'BDC_OKCODE'
'=WB_BACK'.
perform bdc_field using 'DD02D-DDTEXT'
'Stud details'.
perform bdc_dynpro using 'SAPMSRD0' '0102'.
perform bdc_field using 'BDC_CURSOR'
'RSRD1-TBMA_VAL'.
perform bdc_field using 'BDC_OKCODE'
'=BACK'.
perform bdc_field using 'RSRD1-TBMA'
'X'.
perform bdc_field using 'RSRD1-TBMA_VAL'
'ZSTUD1'.
*perform bdc_transaction using 'SE11'.
CALL FUNCTION 'BDC_INSERT'
EXPORTING
TCODE = 'SE11'
POST_LOCAL = NOVBLOCAL
PRINTING = NOPRINT
SIMUBATCH = ' '
CTUPARAMS = ' '
TABLES
DYNPROTAB = BDCDATA
EXCEPTIONS
INTERNAL_ERROR = 1
NOT_OPEN = 2
QUEUE_ERROR = 3
TCODE_INVALID = 4
PRINTING_INVALID = 5
POSTING_INVALID = 6
OTHERS = 7
IF SY-SUBRC <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
ENDLOOP.
CALL FUNCTION 'BDC_CLOSE_GROUP'
EXCEPTIONS
NOT_OPEN = 1
QUEUE_ERROR = 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.
*ENDLOOP.
*perform close_group.
*& Form bdc_dynpro
text
-->P_0207 text
-->P_0208 text
*FORM bdc_dynpro USING VALUE(P_0207)
VALUE(P_0208).
*ENDFORM. " bdc_dynpro
FORM BDC_DYNPRO USING PROGRAM DYNPRO.
CLEAR BDCDATA.
BDCDATA-PROGRAM = PROGRAM.
BDCDATA-DYNPRO = DYNPRO.
BDCDATA-DYNBEGIN = 'X'.
APPEND BDCDATA.
ENDFORM. "BDC_DYNPRO
*& Form bdc_field
text
-->P_0212 text
-->P_0213 text
*FORM bdc_field USING VALUE(P_0212)
VALUE(P_0213).
*ENDFORM. " bdc_field
FORM BDC_FIELD USING FNAM FVAL.
CLEAR BDCDATA.
BDCDATA-FNAM = FNAM.
BDCDATA-FVAL = FVAL.
APPEND BDCDATA.
ENDFORM .
FORM GETFILE USING SUREN.
CALL FUNCTION 'F4_FILENAME'
EXPORTING
PROGRAM_NAME = SYST-CPROG
DYNPRO_NUMBER = SYST-DYNNR
IMPORTING
FILE_NAME = SUREN.
ENDFORM. -
LSMW-Error during processing of BDC session change to material master MM02
I have created an LSMW for changing material master data. I recorded MM02 and using the "select views" screen selected the accounting 2 view and entered the information in the fields on that screen requiring changes. I've set up all of the technical screens for the LSMW. However, when I process the BDC session with "display errors only", the program stops at the select view screen with an error message "Select at least one view". Any ideas how I can process through this screen so that the Accounting 2 screen opens in the BDC session? One further note, I set that selection as a constant in the field mapping and conversion rules screen. The field name recorded as KZSEL_05.
hi
one question how did you choose the view? i mean to ask by scrolling down using mouse or page down.
the scrolling by mouse is not recognized by recording and that may be the error. so whenever you have to go down in screen please use page down not scrolling at least in LSMW. -
Hello!
I have a customer that usually have error status in BDC Sessions and they expect that original users clean up their sessions.
But they are looking for some task in background to help them, is it possible?
And he has another doubt:
"How does the system store the data used in the BDC session? If we have an error and need to correct the data or re-run the session, where will the tool pull the data for that session? We are trying to determine if failed sessions are leaving data on the unix filesystems, etc."
Thanks in advance,
Daniel Kaoro KobashigawaHi,
If you are using the BDC session methos then the error logs and other ino are stored in teh session in SM36
We can re-process the sessiions that are error ones seen in the Error records.
Search SDN more on this.
We have many threads on this issue.
If you are using the Call Transaction then we dont get the exact error but we can see the error records using BDCMSGCOLL.
Usually both are combined to handle the data in a accurate manner.
Regards
Lekha -
How to send error record to session in call transaction method
Hi experts,
I want to send only the error record to session while executing the program in call transaction method. please give me example on this
regards,
siva kumarOne logiv that I can suggest is that after you have got the details of the record in error, you write another perform build_Session and put the below logic in that.
Logic:
1. Build a internal table for the error records similar to the internal table you used for looping for the call transaction. In short this internal table will have only the records that have an error in call transaction.
2. Copy the recordign that you have done before and put it in the perform inside the loop and build the BDC table.
3. Then .using this BDC table you can build the BDC session.
- Guru
Reward points for helpful answers
3.
Maybe you are looking for
-
Color correction, color profile, colorsync, wide gamut,
There hasn't been any reply to the threads about color inconsistency in OS X, so I'm starting another one. I'm using a wide-gamut monitor attached to a Mac with built-in display. When Preview displays an image, it applies some color correction to it.
-
while applying patch 13418800 on e-business 12.1.3 I encountered the following situation The two filenames mentioned below were working for more than 18 hours Worker Code Context Filename Status 1 Run G
-
Unable to view photos although after sycronising after upgrade to IOS 5.1.
Hi, I'm unable to view the photos after syncronising although application shows that I've successfully syncronise 9 photos. None can be displayed.This is after upgraded to IOS 5.1.Pls help.
-
BPM Integration with SQL Authenticator Provider in WebLogic
Hi Gurus, Related to the explanation from this blog : http://orasoa.blogspot.com/2010/06/sqlauthenticator-and-human-worklist.html I have followed this review, I can see all user and groups from sql authenticator provider. And also I can assign bpm ap
-
Hi, I have seen numerous articles explaining svchost, and I think I have a reasonable grasp of it (although basic). My favourite article so far is http://www.bleepingcomputer.com/tutorials/list-services-running-under-svchostexe-process/#advanced, wh