thespot4sap.com independent sap information
 

New - get SAP Access - pay monthly

SAP Tutorials    Online SAP Training    SAP CBT's    Forums    SAP Articles    SAP Jobs    Resumes
  SAP Access    SAP Blogs    SAP Books     Links     Vendor Directory     Submit Content    Search

New Page 1

Previous Page

Next Page

SAP ABAP Queries
Data Retrieval Using Program

Page 7 of 8

Retrieving Data Using Program

Sometimes a situation arises when an ABAP query’s automatic data retrieval facility is not enough to get the desired results. In that case, the steps up to creating the functional area are the same. Only difference is that on the Title and Database screen specify a structure in the field Table and select the field Data Retrieval Using Program.

The default report name given by the system can be overwritten.

This report needs to be defined before hand – because it is used as a model while generating the query report. Thus the report itself remains unchanged but based on that another one is created.

Note: Ensure that the report is free of syntax errors and has the same fixed point arithmetic settings as the functional area.

General Format Of the Report

A typical report of this type will have the following format:

Report <report name>.

Tables: <list of dictionary structures to be used>.

Parameters: <name of parameters>.

Select-options: <name of select options>.

Data: < all internal tables>.

*<query head> This comment should always be after data declarations.

Beginning of a loop to retrieve each record and place it in the field string tab.

Select, do-enddo, loop, etc.

<code to format the data>.

*<query body> This comment should always be the last statement in the loop.

At this stage the data will come into the field string.

Endselect, enddo, endloop.

Next Page

Previous Page

 

New Page 1

 

 


About Us   Contact Us   Privacy   Disclaimer   Feedback   Email Discussion   Newsletter  

Copyright © - Independent SAP Information
Partners: Learn XML, SAPdox, Worldwide Guesthouses and B&B's