Adobe Forms and BDCs

 Adobe forms


Q1. What is Adobe form?

Ans: PDF stands for Portable Document Format. Definition: It is a Universal file format developed by Adobe that preserves all the fonts, formatting, graphics, and color of any source document, regardless of the application and platform used to create it.

Q2. What are components of SAP Script?

Ans:Layout Set, Form, Print Program, Function Modules.

Q3. What are components of Layout Set?

Ans: Header Data, Page,Page Windows, Windows, Paragraph Format, Character Format.

Q4. What is SAP Smart Forms?

Answer :SAP Smart Forms is used to create and maintain forms for mass printing in SAP Systems.As output medium SAP Smart Forms support a printer, a fax, e-mail, or the Internet (by using the generated XML output). SAP introduced SmartForms in 1998 to overcome the limitations in SAP Scripts


Q5. What is interactive form?

Ans:An interactive form is a data-gathering window containing multiple questions that interactively change based on user input. In other words, a user’s response to one question may cause one or more additional questions to be added to the window.

Q6. How to display a logo dynamically in the Adobe Forms?

Ans.   To display a logo dynamically, we will have to upload it first into SAP using transaction SE78. This transaction will store this logo internally into a table “stxbitmaps”.

After uploading the logo we will have to create an interface and we will define two global variables there. Let’s say V1 type XSTRING and V2 type STRING (default value ‘image\bmp’). In Code initialization section we will have to write a simple query to fetch the logo from the table above by providing the log name. Then we will have to call a method cl_ssf_xsf_utilities=>get_bds_graphic_as_bmp and pass on tdobject, tdname, tdid and tdbyte fetched from the query. This method is going to return a XSTRING type variable which we will move to the global variable V1 defined already.

After this step we have to create a Form and assign the interface created above to it. In the right side pane under the context tab, we have to create a graphic node. Select the graphic node and in the properties section make the Graphic Type as Graphic Content. Save it and drag V1 (from the left pane under the Global Data node) to the Field property of the Graphic and V2 (from the left pane under the Global Data node) to the MIME Type property of the form. Under the Layout tab create an image field and bind it with graphic node created. Save and activate. Execute the form. This will display an image dynamically.

Q7. What needs to be done to convert the static text in the form layout to a different language?

Ans.

  • Go to transaction code SFP.
  • Enter your form name and hit display.
  • Now go to menu Goto -> Translation.
  • Give Original Language as EN and Target Language as whatever language you want to convert the static text into and hit enter.
  • You will find two objects TLGS and PDFB.
  • Double click on the form under PDFB tag.
  • Go to menu Utilities -> Expand Tags.
  • You will find vertically cascaded windows for source text and target text.
  • Under the target text press copy source text button. This will copy everything defined as static text in the layout to target text.
  • Now here we can convert the text into the respective language.
  • Once done, save and activate the changes.
  • Come out and execute the form in whatever language you want. Make sure to input the language in LA field of /1BCDWB/DOCPARAMS input table.
  • Execute and see the output.

Q8. What Is Lock Object?

Answer :To synchronize access of several users using same data Lock objects are used.

Q9. What Are The Types Of Subroutines?

Answer :

Internal Subroutines: The source code of the internal subroutines will be in the same ABAP/4 program as the calling procedure (internal call).

External Subroutines: The source code of the external subroutines will be in an ABAP/4 program other than the calling procedure.

Q10. How to create a form object?
Answer: 

Creating a Form Object

Creating a Form Object in the Repository Browser.
You are in the Repository Browser of the ABAP Workbench.
Select a package.

To create a form interface, proceed as follows:

  1.In the context menu of the package, choose
      Create -> Form Object -> Interface.
  2.Enter the name of the interface in the Create Interface dialog box.

To create a form with a context and layout, proceed as follows:

 1.In the context menu of the package, choose
     Create -> Form Object -> Form.
 2.Enter the name of the form in the Create Form dialog box.
 3.Enter the name of the interface that you want the form to use.
 4.Choose Save.
 5.The Create Object Directory Entry dialog box appears.
 6.Enter your data and save the object.

Advanced SAP Adobe Forms Interview and Answers

Q11. List the components involved in creation of Adobe Forms.

And: The components involved in creation of Adobe Forms are Layout, Context and Interface.

Q12. Can we use the same interface in multiple Adobe Forms?

Ans: Yes, we can use same interface in multiple Adobe Forms.

Q13. What are the Scripting languages available in Adobe Forms?

And: There are 2 languages available JavaScript and FormCalc.

Q14. Which type of data processing is supported in PDF forms?

Ans: Client side data processing is supported in PDF forms.

Q15. What are the advantages of Adobe Forms?

Ans: 

  1. Flexible tool for designing the form(WYSIWYG Editor)
  2. Graphics can be included in the form directly. No conversion is required.
  3. Different page orientation like in smartforms. Existing PDF or word document can be imported
  4. Barcodes can be printed on all printers of types Postscript, PCL, PDF, or Zebra.
  5. Form are regular repository objects and has version management.
  6. Forms can be integrated in the browser based environment and made interactive.

Q16. What is smartform?

Answer

Smart Forms are printing forms used to print Invoice and purchase order forms etc. We are calling smartforms from  ABAP programs then spools are generated, now smartform ready to be printed.

SMARTFORMS is the transaction to design the smart form layout.

SMARTSTYLES are used to define paragraph and character formats (fonts, barcodes, etc.)

Q17. How can you make the Smartforms to choose a printer name by default?

Answer

In the CALL FUNCTION of the Smartform Function Module, set the output options parameter to set the printer name.

The output options is of the type SSFCOMPOP which contains the field TDDEST. Set the TDDEST field to your default printer name.

Q18. Where can I provide the input parameters to the smartform?

The input parameters for the smartform can be defined in Global Settings->Form Interface.

The Associated Type must be defined in the ABAP Dictionary.

Q19. How are conditions used in the adobe forms?

Ans. Suppose you want to display a particular text module in case if language you pass is EN in the input parameter. For this follow the steps below


  1. Go to transaction SFP and create a form.
  2. In the context tab, create a Text and assign a Text Module to it (created under smartforms transaction) under its properties.
  3. Click on conditions button and add a row using + button. Give the Import parameter name as EX_LANGU (language parameter in my example) under first OPERAND and ‘EN’ under second OPERAND as shown.
SAP Adobe Forms
  1.  Save and activate the form.
  2.  Execute it by passing EN as language parameter. This time the text module will be displayed. If you execute it by passing FR as language parameter, the text module won’t display on the form output this time.

Q20. Types of Form layout

Answer: 

 Live  Cycle Designer offers two types of form layout techniques for you to work with: 

 Static layout : These forms have fixed layouts. When presented to the end user, the form retains its original layout, regardless of the amount of data available to fill the form.

 Dynamic layout : A form with a dynamic layout is designed to expand or shrink according to the amount of data available to fill it.


Frequently Asked SAP Adobe Forms Interview Questions and Answers

Q21. What’s in a form design?

Answer:

 The following key components make up a form design:

 1.Master pages
 2.Body pages
 3.Content areas
 4.Subforms
 5.Fields
 6.Boilerplate objects

Q22. What is master pages in form design? 

Answer: Every form design contains at least one master page that Live Cycle Designer creates automatically. Master pages define the orientation and dimensions of body pages. Master pages are responsible for formatting body pages. Provide a background and layout format for more than one of the body pages in a form design. Each master page is created with a default content area that covers the whole page.

Q23. What is body pages in form design?

Answer: Body pages

  •  Body pages represent the pages of a form.
  •  Each body page derives its page size and orientation from a master page.
  •  Each body page is associated with the default master page that LiveCycle Designer creates.
  •  You can choose which master page to assign to a body page.

Q24.  What are subforms in form design?

Answer: Sub Forms

  •  Subforms are container objects that you can use to group form design objects including: fields,address,images etc.
  •  A subform provides anchoring, layout, and geometry management for objects.
  •  You can also configure subform objects to be repeatable.

Q25. What are the uses of Form Interface?

Answer:

  1. In the form interface, you specify the data that is exchanged with the application program (such as tables, structures, work areas).
  2. Under Global Definitions, you define your own fields, variables etc.
  3. The system fields contain data with a predefined meaning (such as the date).

Q26. Prerequisites to learn SAP Adobe forms

Ans: No knowledge or experience is required to learn SAP Adobe forms, but the basic knowledge of SAP adds an advantage to learn adobe forms.

Q27. How information is allocated in bunch table?

Ans: 

A bunch table contains information from numerous DDIC tables. It stores data as name esteem combine.

Q28. What are the sorts of Subroutines?

Ans:

1. Interior Subroutines: The source code of the inner subroutines will be in the same ABAP/4 program as the calling method (inward call).

2. Outside Subroutines: The source code of the outer subroutines will be in an ABAP/4 program other than the calling strategy.

Q29. Are SAP Scripts client dependent or independent?

Ans: 

Standard scripts are client independent

User defined scripts are client dependent.

Q30. How do I create an Adobe form?

Answer: 

 To create fillable PDF files:

  1. Open Acrobat:
  2. Click on the “Tools” tab and select “Prepare Form.”
  3. Select a file or scan a document:
  4. Acrobat will automatically analyze your document and add form fields.
  5. Add new form fields:
  6. Use the top toolbar and adjust the layout using tools in the right pane.
  7. Save your fillable PDF:
  8. You can also share it with others or click Distribute to collect responses automatically.

SAP Adobe Forms Interview Questions For Experienced

Q31. What is a function group?

Answer:

A function group is a program that contains function modules.Each function group is identified by a four-character identifier called a function group ID.

Q32. Which are the components of function group?

Answer:

  1. A main program.
  2. A top include.
  3. A UXX include.
  4. A function module include.

Q33. What is MVC in WebDynpro ABAP?

Answer:

Basically WebDynpro follows MVC M-Model(Business logic ) V-View(Screen) C-Controller( Controls screen and Model).

Q34. What is a context in WebDynpro ABAP?

Answer:

Context is a temporary place which stores data in the form of nodes and attributes.

Q35. What Is Sap Style Maintenance?

Answer :

SAP style maintenance is a collection of character & paragraph format.

Q36. How Can You Format The Data Before Write Statement In The Report?

Answer :

By using the loop event the reports output can be formatted

.at first
.at new
.at last

Q37. What Is The Difference Between A ‘database Index’ And A ‘match Code’?

Answer :

Database Index’ contains fields from one table while ‘Match Code’ contain fields from several tables. Match code objects can be built on cluster tables, transparent tables and pooled tables.

Related Interview Questions

  1. SAP HANA Interview Questions
  2. Core Java Interview Questions
  3. JSF Interview Questions
  4. JSP Interview Questions
  5. JPA Interview Questions
  6. Spring Framework Interview Questions
  7. Spring Boot Interview Questions
  8. Core Java Multiple Choice Questions
  9. 60 Java MCQ Questions And Answers
  10. Aricent Java Interview Questions
  11. Accenture Java Interview Questions
  12. Advanced Java Interview Questions For 5 8 10 Years Experienced
  13. Core Java Interview Questions For Experienced
  14. GIT Interview Questions And Answers
  15. Network Security Interview Questions
  16. CheckPoint Interview Questions
  17. Page Object Model Interview Questions
  18. Apache Pig Interview Questions
  19. Python Interview Questions And Answers
  20. Peoplesoft Integration Broker Interview Questions
  21. PeopleSoft Application Engine Interview Questions



Q1. How to display a logo dynamically in the Adobe Forms?

Ans.   To display a logo dynamically, we will have to upload it first into SAP using transaction SE78. This transaction will store this logo internally into a table “stxbitmaps”.

After uploading the logo we will have to create an interface and we will define two global variables there. Let’s say V1 type XSTRING and V2 type STRING (default value ‘image\bmp’). In Code initialization section we will have to write a simple query to fetch the logo from the table above by providing the log name. Then we will have to call a method cl_ssf_xsf_utilities=>get_bds_graphic_as_bmp and pass on tdobject, tdname, tdid and tdbyte fetched from the query. This method is going to return a XSTRING type variable which we will move to the global variable V1 defined already.

After this step we have to create a Form and assign the interface created above to it. In the right side pane under the context tab, we have to create a graphic node. Select the graphic node and in the properties section make the Graphic Type as Graphic Content. Save it and drag V1 (from the left pane under the Global Data node) to the Field property of the Graphic and V2 (from the left pane under the Global Data node) to the MIME Type property of the form. Under the Layout tab create an image field and bind it with graphic node created. Save and activate. Execute the form. This will display an image dynamically.

Q2. What needs to be done to convert the static text in the form layout to a different language?

Ans.

  1. Go to transaction code SFP.
  2. Enter your form name and hit display.
  3. Now go to menu Goto -> Translation.
  4. Give Original Language as EN and Target Language as whatever language you want to convert the static text into and hit enter.
  5. You will find two objects TLGS and PDFB.
  6. Double click on the form under PDFB tag.
  7. Go to menu Utilities -> Expand Tags.
  8. You will find vertically cascaded windows for source text and target text.
  9. Under the target text press copy source text button. This will copy everything defined as static text in the layout to target text.
  10. Now here we can convert the text into the respective language.
  11. Once done, save and activate the changes.
  12. Come out and execute the form in whatever language you want. Make sure to input the language in LA field of /1BCDWB/DOCPARAMS input table.
  13. Execute and see the output.

    

Q3. How to convert the text module used in the adobe form to a different language and display it?

Ans. Create a text module (eg: lets say we create Z_TEST_DEMO) in the SMARTFORMS transaction (in EN transaction). Create a Text (eg: lets say we create T1) in the adobe form (SFP transaction) and assign the created text module TM1 (in smartforms transaction) to the text (in form using SFP transaction).

Execute and see the output.

Now what if you want to display it in the language FR. For that please follow the steps below:

  1. Go to transaction SE63.
  2. Then go to menu Translation -> ABAP Objects -> Other Long Texts

1.JPG

  3.   Then under Object Type selection window, select B5 SAPScript: Forms and Styles and double click on SSF Smart Form

2.JPG

  4.   Give the Text Module’s name (Z_TEST_DEMO) created above and select source language as EN and Target Language as FR and hit Enter

  5.   Then in the Target text give the French translation of English text and give the same paragraph format (which in this case you will see as * on the left of the text in target language section below:

3.JPG

  6.   Press Save Active button.

  7.   This will activate all the changes.

  8.    Now go to your form and execute it as the text has already been assigned with the text module. Give language as FR. This will show the French text. And if you put EN as language, this will show text in English instead.

Q4. How to bind a static text box with a dynamic field coming from a table as an input?

Ans. For example you want to display

First Name       Scott

where First Name is a static text which you have already added in the form layout and Scott is the name of the person you want to pick from a table as per whatever conditions you have written in your code in the driver program. For this scenario, follow the steps:

  1. In the form layout drag a text-field from the library to the design window.
  2. On the layout tab of the properties window (for the selected text-field), select position as left and reserve as 1in.

4.JPG

  3.   Then on the field tab under the object tab, put caption as First Name and appearance as Sunken Box as shown

5.JPG

  4.   Then in the binding tab under the object tab select the data binding and bind it with the respective field.

6.JPG

  5.   Save and activate and get the result.

When you have used a text instead of text-field then, right click on text and select edit text. Write First Name: and then again right click and select Floating field. Select the object property of that floating field and click on the binding tab and define the binding with whatever field you want to put in there.

Q5. How are conditions used in the adobe forms?

Ans. Suppose you want to display a particular text module in case if language you pass is EN in the input parameter. For this follow the steps below

  1. Go to transaction SFP and create a form.
  2. In the context tab, create a Text and assign a Text Module to it (created under smartforms transaction) under its properties.
  3. Click on conditions button and add a row using + button. Give the Import parameter name as EX_LANGU (language parameter in my example) under first OPERAND and ‘EN’ under second OPERAND as shown.

1.JPG

  4.   Save and activate the form.

  5.   Execute it by passing EN as language parameter. This time the text module will be displayed. If you execute it by passing FR as language parameter, the text module won’t display on the form output this time.




  1. What is the use of NACE table in SAP Adobe Forms?
  2. How to add logo in SAP Adobe Forms?
  3. Differentiate between a Character Design and Paragraph Design in SAP Adobe Forms.
  4. What are different ways to pass information to SAP Adobe Forms?
  5. Differentiate between SAP Adobe Forms and SAP Smart Forms.
  6. Differentiate between SAP Adobe Forms and SAP Scripts.
  7. Name the capacity Modules and diverse print modes utilized as a part of print program.
  8. How to dynamically display logo in SAP Adobe Forms?
  9. What are the steps involved to convert static text in form layout of SAP Adobe Forms to a different language?
  10. How to bind a static text with a dynamic field data coming from a table in form of input in SAP Adobe Forms?
  11. How to use conditions in SAP Adobe Forms?






BDC




What is BDC?

BDC stands for Batch Data Communication. BDC is used to upload data from flat file to SAP.

What are the different methods of BDC?

  • Batch input session method
  • Call Transaction method

What is the t-code to display batch input sessions?

SM35

What is the t-code for transaction recorder?

SHDB

What are the function modules used to create batch input session?

Function Module NamePurpose
BDC_OPEN_GROUPUsed to create session
BDC_INSERTUsed to insert batch input data
BDC_CLOSE_GROUPUsed to close session. We can process the session only after is closed

What are the parameters in BDC_OPEN_GROUP?

ParametersPurpose
CLIENTClient in which session to be processed
GROUPName of the session
HOLDDATELock date
KEEPKeep session even after successful processing
USERThis is used to check the user authorizations to run the transactions

What are the parameters in BDC_INSERT?

ParametersPurpose
TCODETransaction Code
DYNPROTABContains transaction data

What is the syntax for Call Transaction?

CALL TRANSACTION <tcode> USING <bdctab> MODE <mode> UPDATE <update> MESSAGES INTO <bdc_msg_coll>.

What are the differences between session method and call transaction method?

Call Transaction MethodSession Method
Asynchronous processingSynchronous processing
No logs will be created, so errors have to be handled explicitlyLogs will be created
SY-SUBRC = 0, if it is successfulSY-SUBRC will not be returned
Database updates are synchronous or AsynchronousSynchronous database updates

What is the ABAP program name to process the batch input session automatically?

RSBDCSUB



  1. Question 1. If I Want To Execute A Program Only In Background Not In Foreground Is There Any Option For This?

    Answer :

    In Session method, in SM35 when you process the batch, you need to select the radio button Background, so it will run in background. In call transaction you need to mention the Mode value as N (no screen), so that it will run in background.

  2. Question 2. Where Can You Find Error Log For Call Transaction?

    Answer :

    1. Declare it_bdcmsgcoll type bdcmsgcoll.
    2. Declare to hold messages like Message (100) and w_msg TYPE bdcmsgcoll,
    3.  Call transaction like below
      CALL TRANSACTION MM01 USING IT_BDCDATA UPDATE S MESSAGES INTO IT_BDCMSGCOLL.
    4. IF SY-SUBRC <> 0.
    5. loop at it_bdcmsgcoll into wa_bdcmsgcoll where w_msg = E;.
      CALL FUNCTION MESSAGE_TEXT_BUILD
      EXPORTING
      msgid = wa_bdcmsgcoll-msgid
      msgnr = wa_bdcmsgcoll-msgnr
      msgv1 = wa_bdcmsgcoll-msgv1
      msgv2 = wa_bdcmsgcoll-msgv2
      msgv3 = wa_bdcmsgcoll-msgv3
      msgv4 = wa_bdcmsgcoll-msgv4
      IMPORTING
      message_text_output = w_message.
    6. FM will genrate meaningful Error Discription :w_message.

  3. Question 3. How To Write A Code For Multiple Transactions?

    Answer :

    you should Write BDC_Insert Function module Twice. Remaining Function modules like BDC_group_open and BDC_close_group should be write once there...you can pass two or more transaction code in BDC_insert function module.


  4. Question 4. Power Is Interrupted While Transferring Data From Internal Table To Application Server. How Will You Determine Many Records Are Transferred In Session Method And Call Transaction Method?

    Answer :

    Check no. of records already updated and delete them from input file and run BDC again.

  5. Question 5. How Do You Send Files To The Legacy Systems From Sap And Vice Versa? How Does One Know That The Legacy Files Have Come On To The Sap Server You Are Working On?

    Answer :

    BDC is used to transfer the data from legacy system to SAP system & vice versa...

    We can send the files from SAP to legacy system thru datasets (open dataset for output...) & GUI_download (F'n Module)..

  6. Question 6. What Is The Structure Of Bdcmsgcoll?

    Answer :

    Go to se11 and enter bdcmsgcoll in database table filed and click on display it will displayed all the fields that are existing in the bdcmsgcall structure.


  7. Question 7. While Doing Bdc Exp Va01 Transaction Sometime In The Item Level Data Shows Only 4 Items And Other Times It Will Show 6 Line Items, How Will You Maintain This Kind Of Screen Resolutions Scenerio?

    Answer :

    Fill the CTUPARAM structure for Screen resolutions , and call this structure using options from CTUPARAM in Call Transaction Syntax

  8.  
  9. Question 8. How To Handle Error In Session Method?

    Answer :

    In session method the system automatically handled the error.goto sm35select the session name ,then select the analysis tab button in the top after that select the Log created, Here we can see the error record.


  10. Question 9. What Should Be The Approach For Writing A Bdc Program?

    Answer :

    1. Create recording
    2. Transfer the data from legacy system to internal term
    3. From internal table transfer the data to BDC structure
    4. Create session or use call transaction method to update data to database table.

  11. Question 10. What Are The Types Of Records That Are Transferred To Sap R/3 And Used By Interfaces?

    Answer :

    Any type of records can be transferred to SAP R/3

  12. Question 11. Explain About Sap Fico Testing And The Tools Used?

    Answer :

    If you want to do FICO testing, you need to know the FICO process in SAP and also need to be familiar with the T-Codes and their functionality. A bit of Configuration knowledge is also required to test FICO.

    Tools: LSMW and BDC tools willl be used for data migration and loading the transactional/Master data in SAP.

  13. Question 12. How Can We Use Multiple Transactions By Using Bdc_insert?

    Answer :

    In the function module t-code here mention transaction code, and dynprotab here mentioning internal table name ,calling no of times a FM and assing TCODE and INTERNALTABLENAME


  14. Question 13. How To Write A Code In Tab Control?

    Answer :

    For tab control we have to use concatenate options in your coding.

  15. Question 14. What Are The Table Controls In Bdc ? What Is The Difference Between Bdc And Lsmw ?what Is The Difference Between Bdc And Rfc ?

    Answer :

    BDC - Batch data communication in which there are 2 processes

    1. in bound
    2. outbound

    RFC - remote fucntion call(or) calling


  16. Question 15. What Is The Use Of Table Control In Bdc Is It Same In Module Pool Table Control?

    Answer :

    Yeah that table control is same as that used in module pool here we do recording

  17. Question 16. How Do You Write Manual Bdc Session Method?

    Answer :

    Steps to create manual BDC session

    1. Use BDC_OPEN_GROUP to open the session
    2. loop on the internal table which you will use in transaction , stps of BDC transaction recording
      Use BDC_INSERT to insert 1 transaction in Session
      endloop
    3. Use BDC_CLOSE_GROUP to close the session .


  18. Question 17. How Can We Handle Table Control In Bdc?

    Answer :

    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 

  19. Question 18. Update Types In Call Transaction Method. What Is The Difference ?

    Answer :

    Calltransaction update types:update types : S /A/LS-SYNCHRONOUSA-ASYNCHRONOUSL-LOCAL MEMORYsynchronous mode is waiting for commit work and asynchronous is not waiting for commit work.


  20. Question 19. Can We Handle Two Transaction Codes In The Same Program Using Call Transaction Bdc Input Method?

    Answer :

    No.

  21. Question 20. Have You Set Up A Back Ground Job ? How To Create A Background Job Without A Variant ?

    Answer :

    Yes, user can create background job scheduling in two ways.

    1. By calling the executable program RSBDCSUB
    2. Transaction Code SM37


  22. Question 21. What Is The Difference Between Rfc And Bapi Function Modules?

    Answer :

    BAPI's are the remote enabled Function modules which are defined in the Business Object Repository (BOR) as the methods of the business objects.I can say BAPI is the subset of RFC. RFC connects to the other system via BAPI and vice versa.

  23. Question 22. What Is The Difference Between Upload And Ws_upload ?

    Answer :

    The diffrence 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.


  24. Question 23. How Can We Upload A Text File Having Delimiters In To Legacy System?

    Answer :

    For up loading?text file we use the pre-defined FM gui_upload. in that FM we have the parameter has_field_seperator, for that we assign the default delimiter 'x'.

    ?????????? HAS_FIELD_SEPERATOR = 'X'

    'X' can provide the What ever delimiter we used in flat file for seperation.

  25. Question 24. Why Lsmw Does Not Support Call Transaction Method?

    Answer :

    Lsmw is one time requirement call tr. doesn't have log file. we have to maintain explicitly


  26. Question 25. How Table Control Cn Be Generated Using Bdc?

    Answer :

    Using index

  27. Question 26. How To Transfer Data Into Line Items Using Batch Input Session Method?

    Answer :

    table controls


  28. Question 27. Use If Idoc And Bapi?

    Answer :

    idoc is carry data from one server to other server,bapi can be used to update the data base table with legacy system data.

  29. Question 28. How To Handle Errors In Call Transaction Bdc Method Without Using Bdcmsgcoll Internal Table?

    Answer :

    We can use session method logfile in call transaction.

    1. We have to send error records in to one internal table .
    2. Next for that itab u can use session method .
    3. with this u will get session method log file in call tran.

  30. Question 29. What Is The Difference Between Call Transaction And Session Method?

    Answer :

    Call trasaction method trasfers non sap data into sap immediately after completion of BDC, whereas session method creates the session and transfers data when user seesions it. It tranfers data one by one whereas trasaction method transfers data all together.

  31. Question 30. How Do We Assign Dynamic Views While Creating Material Master And Generating Bdc?

    Answer :

    By defining the view index as like as table control Index value. Suppose if view is in 9th position value, then assign this value to index .

  32. Question 31. From Excel To Abap - Is Batch Mode Possible ?

    Answer :

    DATA  w_file TYPE string.
    * Convert the file path into string
      w_file = p_input.
    * Internal Table should have same field sequence as EXL File.
      CLEAR   t_upload.
      REFRESH t_upload.
    * Call function to upload the data into internal table
      CALL FUNCTION 'GUI_UPLOAD'
        EXPORTING
          filename                = w_file
          filetype                = 'ASC'
          has_field_separator     = 'X'
        TABLES
          data_tab                = t_upload
        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 NE 0.
    *    MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
    *            WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
      ELSE.
    *   Delete the first row of heading from the uploaded table
        DELETE t_upload INDEX 1.
      ENDIF.       " IF sy-subrc EQ 0.

  33. Question 32. How To Load Data From Ms Excel Sheet To Sap By Using Bdc Method ?

    Answer :

    Using function module UPLOAD or WS_UPLOAD or GUI_UPLOAD, but we need to give file type as 'wxi'. OR use function module : alsm_excel_to_internaltable.

  34. Question 33. What Is The Diffreence Between The Following.a) Bdc_open_group And Bdc_open_dataset.b) Bdc_close_group And Bdc_close_dataset?

    Answer :

    No function module named BDC_OPEN_DATASET is exist .


What is full form of BDC Session?

Batch Data Communication Session.

2.  What are the steps in a BDC session?

The first step in a BDC session is to identify the screens of the transaction that the program will process.  Next step is to write a program to build the BDC table that will be used to submit the data to SAP. The final step is to submit the BDC table to the system in the batch mode or as a single transaction by the CALL TRANSACTION command.

3. How do you find the information on the current screen?

The information on the current screen can be found by SYSTEM à
STATUS command from any menu.

4.  How do you save data in BDC tables?

The data in BDC tables is saved by using the field name ‘BDC_OKCODE’ and field value of ‘/11’.

5. What is the last entry in all BDC tables?

In all BDC tables the last entry is to save the data by using the field name BDC_OKCODE and a field value of ‘/11’.

6.  What is a multiple line field?

A multiple line field is a special kind of field which allows the user to enter multiple lines of data into it.

7.  How do you populate data into a multiple line field?

To populate data into a multiple line field, an index is added to the field name to indicate which line is to be populated by the BDC session (Line index).

8.  Write the BDC table structure.

BDC table structure

FIELD                     TYPE                            DESCRIPTION

Program                CHAR (8)                      Program name of transaction.

DynPro                 CHAR (4)                      Screen number of transaction.

DynBegin              CHAR (1)                      Indicator for new screen.

Fnam                    CHAR (35)                     Name of database field from screen.

Fval                      CHAR (80)                     Value to submit to field.

9. Does the CALL TRANSACTION method allow multiple transactions to be processed by SAP?

No.  The CALL TRANSACTION method allows only a single
transaction to be processed by SAP.

10.    Does the BDC-INSERT function allow multiple transactions to be processed by SAP?

Yes.

11.    What is the syntax for ‘CALL TRANSACTION’?

CALL TRANSACTION trans [using bdctab MODE mode].

Three possible entries are there for MODE.

                  A          –           Show all screens.

                  E          –           Show only screens with errors.

                  N          –           Show no screens.




What is BDC and why do we use BDC ?
BDC ( Batch Data Communication ) also known as batch input is a technique by which large volumes of data can be transferred from Non Sap or Legacy systems to SAP systems.
BDC in SAP
Example:  A Legacy system that is to be replaced by SAP has say 1000 Customers , 2000 vendors and 3000 materials. All this data needs to be transferred to SAP . In such cases , We can use BDC.

If the old system is replaced by SAP, such a transfer is called Conversion.
If the old system runs along with SAP, in that case the transfer is called an Interface.

The two methods for BDC are:
  • Session Method
  • Call TRANSACTION Method
  • CALL DIALOG (Outdated)

ABAP interview questions on BDC:

Important:
Question 1:What is the difference between Call Transaction Method and the Session method ?

Session Method
Call Transaction
Session method id generally used when the data volume is huge.
Call transaction method is when the data volume is   low
Session method is slow as compared to Call transaction.
Call Transaction method is relatively faster than Session method.
SAP Database is updated when you process the sessions. You need to process the sessions separately via SM35.
SAP Database is updated during the execution of the batch input program.
Errors are automatically handled during the processing of the batch input session.
Errors should be handled in the batch input program.

Important:
Question 2: 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.

Important:
Question3: Is there any method apart from BDC for data upload to SAP?
Apart from BDC and LSMW, you can use BAPIs to upload data into SAP.
BAPIs should be preferred over BDCs, because they process data faster than BDC.
A BAPI is faster since it updates Database "directly". Whereas BDC calls transaction and goes through the whole screen sequence as any user would do.

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.


Question 4: How do you process errors in Call Transaction method ?

Let's have a look at the syntax for CALL TRANSACTION method.
Sample code:
DATA: BEGIN OF G_T_MESSTAB OCCURS 0.
        INCLUDE STRUCTURE BDCMSGCOLL.
DATA: END OF G_T_MESSTAB.

CALL TRANSACTION 'MB11'
    USING G_T_BDCDATA
          MODE 'E'
          UPDATE 'S'
          MESSAGES INTO G_T_MESSTAB.

All the error messages will be trapped inside G_T_MESSTAB.

Question 5: What is the use of program RSBDCSUB?
There are two ways to process the BDC sessions:
1) Go to SM35 ---> Choose session ---> hit process.
     Now See Question no. 10.
2) Use program RSBDCSUB.
     RSBDCSUB schedules the session to be processed in background.


Let's take an example to understand this.

The sessions are created at one point of time and processed at other point of time and this may create a problem: For example: a BDC program creates a session for updating 1500 customers in SAP. However , before this session is processed via SM35 , a user inserts 100 customers in the system manually. In this case , the session will have at least 100 errors when the session is processed from SM35.

One way to avoid this is to use the program "RSBDCSUB" in the batch input program itself so that the session is processed as soon as it is created.
RSBDCSUB schedules the session to be processed in background.

Question 6: What is the structure of the BDC table?

The BDCDATA consists of the following fields:
§  PROGRAM [CHAR 40] - Online program name.
§  DYNPRO [NUMC 4] - Screen number.
§  DYNBEGIN [CHAR 1] - Flag to indicate the start of a new screen.
§  FNAM [CHAR 132] - Field name of a screen field to be filled with data.
§  FVAL [CHAR 132] - The actual value to be filled into the specified screen field.

Sample Screenshot:
BDCDATA structure
BDCDATA table structure

Question 7: What is the difference between BDC_OKCODE and BDC_CURSOR?

BDC_OKCODE: is used for storing commands during the recording. like '/00' is the command for 'ENTER' Key.
BDC_CURSOR: contains the cursor position. it contains the field in which cursor will be.

Example code:
perform bdc_field       using 'BDC_CURSOR'
                                                'PROJ-PSPID'.
perform bdc_field       using 'BDC_OKCODE'
                                                '=BU'.

Question 8: What are the 3 methods that we use in sequence in a Batch input session method ?

1) BDC_OPEN_GROUP for opening the Batch Input Session
2) BDC_INSERT for inserting the transactional data into SAP
3) BDC_CLOSE_GROUP for closing the Batch Input Session

If there are n records , the BDC_INSERT method should be called n times.
BDC_OPEN_GROUP and BDC_CLOSE_GROUP are called only once.

General Information about a session is stored in table APQI.

Transaction data for a session is stored in table APQD.

Question 9: What is your approach for writing a BDC program?


Identify the Tcode and do the recording in SHDB to populate the BDCDATA.



Once the recording is done , one can Transfer it to the Batch input program.




In the batch Input program , The transactional data is read from the file to an internal table.

Then one can loop over the transactional data in the internal table and start uploading the data in SAP either by CALL TRANSACTION method or by creating sessions through the batch input program.

Question 10: How do you process errors in Session method ?
You can go to Transaction SM35 , Choose the session name and click on Process.

Question 11: What are the different modes of processing batch input sessions?  


The three modes are:


Foreground


Display Errors Only


Background

Question 12: What is the difference between Synchronous and Asynchronous Update ?
In Synchronous update , the database is updated before the next transaction is taken for processing in a batch input.
In Asynchronous update , the system doesn't wait for updating the database before the next transaction is taken for processing in a batch input.



Question 13: What is the transaction for Recording BDC ?

The Tcode is SHDB.

Question 14: 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 .

Question 15: 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



What is BDC programming ?

Transferring of large/external/legacy data into SAP system using Batch Input programming. Batch input is a automatic procedure referred to as BDC(Batch Data Communications).The central component of the transfer is a queue file which receives the data via a batch input programs and groups associated data into sessions.


Can we write the code both call transaction and session method in single program?

Yes it is possible to write call transaction and session in one program.


Which BDC technique you prefer?

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. (This is more genric answer but you can add more on to this if you have worked on BDC)


When you prefer LSMW in SAP?

When we need to update medium amount of data we use LSMW. LSMW is also used when the person like functional consultant has less programming language.


Which BDC you prefer for data migration?

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.


What is the last entry in all BDC tables?

In all BDC tables the last entry is to save the data by using the field name BDC_OKCODE and a field value of of ?/11?.


What is the transaction for Recording BDC ?

Transaction Code for recording is SHDB


Can you set up background processing using CALL TRANSACTION?

Yes, Using No Screen Mode in 'CALL TRANSACTION'


How do you read files from the Application server ?

To read files from Application server You need to use the commands:

OPEN DATASET ---> opens the file(dataset) either in read /write mode. <.p>
READ DATASET ---> Read the file
CLOSE DATASET ---> Close the dataset once the date has been read .

How do you read/write files from/to the presentation server in SAP ABAP ?

You need use the below Function Modules to read/write :

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

What is the structure of the BDC table?

The BDCDATA consists of the following fields:

PROGRAM [CHAR 40] - Online program name.
DYNPRO [NUMC 4] - Screen number.
DYNBEGIN [CHAR 1] - Flag to indicate the start of a new screen.
FNAM [CHAR 132] - Field name of a screen field to be filled with data.

FVAL [CHAR 132] - The actual value to be filled into the specified screen field.

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.


Can we use call transaction and session method in the same program ? explain ?



Yes, we can call call transaction and session method in same program, generally we use call transaction for updating and session method for logging errors in the same program .

Comments

Popular posts from this blog

CDS tutorial and interview questions

AMDP SAP HANA

Differences