Sei sulla pagina 1di 9

1

Q What are Conversion & Interface programs in SAP?


Ans CONVERSION: Conversion refers to BDC programming. Data upload from legacy
system in flat files format to SAP system is done via Conversion Objects. This involves
uploading data through BDC, LSMW, BAPI, etc.
INTERFACE: Flat file to SAP system i.e. idoc, bapi.
Interfaces are ALE/IDOCs development. Involves not just ABAP programming for IDOCs
but also IDOC customization.
Conversions are written to load data into SAP onetime. These are typically file based.
Interfaces are written to exchange/update/send/receive data between SAP and other
systems on an ongoing basis. These can be in many forms, file based, idoc based, real
time(business connector, XI etc are useful in this), xml, and the list goes on.
Q What is BDC?
It is a type of CONVERSION in SAP. To convert Non-SAP data to SAP. BDC is an Inbound
Data Transfer Technique to transfer data from SAP/Non-SAP to SAP System.

However, it_message here contains only the message id and message number values.
So, we have to get the message out of it using the function module
'MESSAGE_TEXT_BUILD' or 'FORMAT_MESSAGE'.
Example :
LOOP AT it_message INTO wa_message WHERE msgtyp EQ 'E'.
CALL FUNCTION 'MESSAGE_TEXT_BUILD'
EXPORTING
MSGID
= wa_message-msgid
MSGNR
= wa_message-msgnr
* MSGV1
=''
* MSGV2
=''
* MSGV3
=''
* MSGV4
=''
IMPORTING
MESSAGE_TEXT_OUTPUT
= wa_text
ENDLOOP.
Difference Between BDC and BAPI?
BAPI

BDC

BAPI is faster than BDC.

BDC is relatively slower than BAPI.

BAPI directly updates database.

BDC goes through all the screens as a


normal user would do and hence it is slower.

No such processing options are available


in BAPI.

Background and Foreground processing


options are available for BDC.

BAPI would generally used for small data


uploads.

BDCs would be preferred for large volumes


of data upload since background processing
option is available.

For processing errors, the Return


Parameters for BAPI should be used. This
parameter returns exception messages or
success messages to the calling program.

Errors can be processed in SM35 for session


method and in the batch input program for
Call Transaction method.

Q What do you do when the system crashes in the middle of a BDC batch
session?
Ans We will look into the error log file (SM35). Check number of records already
updated and delete them from input file and run BDC again.
Q What do you do with errors in BDC batch sessions?
Ans We look into the list of incorrect session and process it again. To correct incorrect
session, we analyze the session to determine which screen and value produced the
error. For small errors in data we correct them interactively otherwise modify batch
input program that has generated the session or many times even the data file.
Q What is the difference between Upload and WS_Upload ?
The difference between WS_Upload and Upload is when you use function Upload it
prompts for a dailog box where in you need to key in the file location. Where as in case
of WS_Upload you specify the file location in the function input parameters itself
Q If I want to execute a program only in background not in foreground is
there any option for this?
The sm37 transaction can be used for running a program in the background. Also in the
session method while processing the session you can specify the processing type as
background or foreground.

Q How to assign multiple transaction codes in a session method to


BDC_Insert function module?
Call function ' BDC_Insert'
exporting
tr. code = ' enter tr.code1 here'
table = 'give an internal table related totr.code1 here'
call function 'BDC_INSERT'
exporting
tr.code = ' enter 2nd tr code'
tables = ' 2nd internal table'

Q. Can we write the code both call transaction and session method in single
program?
Ans. Yes it is possible to write call transaction and session in one program.
Q Which BDC you prefer?
Ans. If we want to transfer large amount of data and when we need to use more than
one transaction code we prefer session method. For small or less amount of data and
for single transaction use call transaction.
Q How can we handle table control in BDC?
Ans.We can handle table control using line index
Line index indicates which line of Table control is to be use for BDC transaction
Ex perform bdc_field using RC29K-AUSKZ(01)
Indicates 1st line of table control is going to be used for transaction which is Line index
of Table Control
Q How do you do BDC for a table control?
With other things as usual, there is a special trick that you have to use while doing BDC
for table control. You need to use the BDC OKCODE =P+.
Its the BCD_OKCODE for Page down that can be used for scrolling down in table control.
Q How do you read files from the Application server ?
You can use the commands:
OPEN DATASET > opens the file(dataset) either in read /write mode.

READ DATASET > Read the file


CLOSE DATASET > Close the dataset once the date has been read .
Q How do you read files from the presentation server ?
You can use the Function Modules :
GUI_UPLOAD > To read data from file into an internal table
GUI_DOWNLOAD > To write data from internal table to a file on presentation server
Q How can we call, call transaction and session method in the same
program?
Ans: You can call both methods by using the standard include BDCRECX1.
Q Suppose in the BDC call transaction we updated one record into the
database. In the message log it is showing successful, but it was not updated
into the data base? How can we handle?
Ans: User COMMIT WORK.

Q What are the problems in processing batch input sessions and How is
batch input process different from processing online ?
PROBLEMS:
i) If the user forgets to opt for keep session then the session will be automatically
removed from the session queue(log remains). However if session is processed we may
delete it manually.
ii)if session processing fails data will not be transferred to SAP database table.
Q how do you save data in bdc tables?

Ans: the data in bdc table is saved by using the field name BDC_OKCODE and field
value of /11.
Q what is the last entry in all bdc tables?
Ans: the last entry of all bdc tables is to save the data by using the field name
BDC_OKCODE and field value of /11.

Potrebbero piacerti anche