2006 Jan 27 6:22 AM
Hi Friends,
Can any body give the answers to the follwong BDC queries?
1.is it possible to incude two transactions with one group name in one program in session method?
2.Suppose we transfer data through BDC from leagacy to SAP and there is some duplicate data in legacy system but we don't want this in SAP system .So how can we check that this data is already exist?
3.Can we use two transaction code in one BDC like XK01 & XD01 if yes how?
4.Can we use Session method & Call transaction both in one BDC if yes
please give me example and scenerio where we use this.
2006 Jan 27 6:27 AM
Hi jak,
1. .is it possible to incude two transactions with one group name in one program in session method
ABSOLUTELY NO
2.
Suppose we transfer data through BDC from leagacy to SAP and there is some duplicate data in legacy system but we don't want this in SAP system .So how can we check that this data is already exist?
We have to check this
in our program
for that particular record
explicitly
before populating the bdc table
for that data.
3.
Can we use two transaction code in one BDC like XK01 & XD01 if yes how?
No we cannot do in one bdc.
Ya, but we can do in one program
4.
Can we use Session method & Call transaction both in one BDC if yes
please give me example and scenerio where we use this.
Ya, logically we can use
by writing code for sesesion and call transaction
sepearately
in the same program.
BUT,
practically this kind is never used.
BCOS,
CALL Transaction will update data,
immediately,
whereas,
for session,
we have to SEPARATELY run the session,
so that data is updated.
regards,
amit m.
Hi Friends,
Can any body give the answers to the follwong BDC queries?
1.is it possible to incude two transactions with one group name in one program in session method?
2.Suppose we transfer data through BDC from leagacy to SAP and there is some duplicate data in legacy system but we don't want this in SAP system .So how can we check that this data is already exist?
3.Can we use two transaction code in one BDC like XK01 & XD01 if yes how?
4.Can we use Session method & Call transaction both in one BDC if yes
please give me example and scenerio where we use this.
2006 Jan 27 6:27 AM
Hi jak,
1. .is it possible to incude two transactions with one group name in one program in session method
ABSOLUTELY NO
2.
Suppose we transfer data through BDC from leagacy to SAP and there is some duplicate data in legacy system but we don't want this in SAP system .So how can we check that this data is already exist?
We have to check this
in our program
for that particular record
explicitly
before populating the bdc table
for that data.
3.
Can we use two transaction code in one BDC like XK01 & XD01 if yes how?
No we cannot do in one bdc.
Ya, but we can do in one program
4.
Can we use Session method & Call transaction both in one BDC if yes
please give me example and scenerio where we use this.
Ya, logically we can use
by writing code for sesesion and call transaction
sepearately
in the same program.
BUT,
practically this kind is never used.
BCOS,
CALL Transaction will update data,
immediately,
whereas,
for session,
we have to SEPARATELY run the session,
so that data is updated.
regards,
amit m.
2006 Jan 27 6:27 AM
1.It is not possible to incude two transactions with one group name in one program in session method
4.Call transaction processes the data immediately whereas you can schedule it later in Session method.
2006 Jan 27 6:31 AM
Hi Jak,
1. under one group you cannot use two trxns.
3. you can use, by writing two different BDC's inone program.
4. yes, you can use both this is possible.
regards
vijay
2006 Jan 27 6:32 AM
Hi Jak,
i hope these links will give you an idea of what BDC is..
In case the field alredy exists in the SAP ..it will be checked automatically..in case it is primay in the table..
http://www.sap-img.com/abap/difference-between-batch-input-and-call-transaction-in-bdc.htm
2006 Jan 27 3:35 PM
1) and 3) Yes - it's quite easy to use different transactions in one session. Generally, you do this if you have similar transactions that you want to call in different situations:
*&---------------------------------------------------------------------*
*& Form LOAD_BUDGET
*&---------------------------------------------------------------------*
form load_budget.
perform open_batch_session using job_name.
* add supplements to batch input session -------------------------------
loop at raw_int
where type = 'S'.
perform rollup_header.
perform rollup_line.
perform rollup_save.
perform insert_batch_session using 'FM9G'.
endloop.
* add returns to batch input session -----------------------------------
loop at raw_int
where type = 'R'.
perform rollup_header.
perform rollup_line_r.
perform rollup_save.
perform insert_batch_session using 'FM9I'.
endloop.
* close and execute batch input session --------------------------------
perform close_batch_session.
* PERFORM START_BATCH_SESSION USING JOB_NAME.
endform. " LOAD_BUDGET
4) Also yes - if you have a call transaction session that fails for some reason, you can turn around and put the transaction into a session. This gives the user an opportunity to analyze and fix the problem:
*& call transaction and capture results
clear sy_int.
call transaction 'FM28' using bdcdata mode p_dmode update 'S'
messages into messtab.
move-corresponding sy to sy_int.
if sy_int-subrc = 0. "fails
tran_int-subrc = 0.
else.
tran_int-subrc = 1.
if p_test ne 'X'.
perform batch_input using 'FM28'.
endif.
endif.
if p_test ne 'X'.
move sy-msgv1 to tran_int-doc#.
endif.
if p_test ne 'X'.
move sy-msgv1 to tran_int-doc#.
endif.
perform get_message using sy_int
changing tran_int-text.
Rob
2006 Jan 27 4:02 PM
Bdc queries
Posted: Jan 27, 2006 1:22 AM
1.It is not possible to have two transactions with one group name in session method.
2.Read the database table with the available key and remove those records from the legacy file to avoid duplicate records.
3.First Call transaction XK01 after completing this call transaction XD01
4.You can use Session method & Call transaction both in one BDC program.
Call transaction method for XK01
Example . Call transaction XK01
using bdcdata
mode ctumode
update cupdate
messages into messtab.
Session Method use function modules for transaction XD01
call function 'BDC_OPEN_GROUP'
call function 'BDC_INSERT'
call function 'BDC_CLOSE_GROUP'.
Hope this helps.
Regards,
Sudheer
| User | Count |
|---|---|
| 3 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |