sitemap
SapMaterial.com
Using logical databases

Tansaction: SE36 Logical datbase builder

Suzanne Farmer:

You declare a logical database(ldb) in the attributes of the report. You just enter the 3 letters of the
ldb . ie DDF, BRF, PNP etc. another method
is in the rpeort declaration - REPORT ZPROGRAM DEFINING DATABASE BRF.

In the dictionary (SE11) you can do a where used list for a table you want to use and specify looking
in ldb.

A logical database is a program which defines a logical structure of tables. It selects the data from
these tables either as select * or select fields formats. There has to be a means of getting the
records from the ldb into
the report. the command you use is GET tablename to retrieve the data from the ldb.

GET tablename is an event (GET is not always an event, but GET tablename is)

Example. (using BRF)

Start-of selection.
GET BKPF.
Code.
Code.

GET BSEG.
Code
Code.

End-of-selection.

This example gets the first record from BKPF and processes the code for that. Then it gets the first
related record from BSEG and processes it, then next BSEG (until no more related to first BKPF) and
then the next BKPF and so on. It's kind of like nested selects only quicker!

It is sometimes possible to say GET tablename fieldnames, but this depends whether the ldb is
written with select * or select fields. Only if it is

written with select fields can you use GET tablename fieldnames. A disavantage of ldb's is that it has
to get retrieve data in the order of
it's own hierarchy, so if you only want data from 2 of the lower tables it still has to retrieve the
higher ones first. It's always best to look at the
structure of all ldb's containing the tables you want to use so you can find the best one for your
purpose.

The HR ldb's are a bit different because they use infotypes which have to be declared. There are
also macros for data retrieval in HR. this is not really my specialist area although I have done quite a
lot of HR programming. I may be able to help if you have specific questions about HR logical
databases but I'm sure someone else in the gourp will have more knowledge than me about this.
All of the  product names here are trademarks of their respective companies.  The site
www.allsaplinks.com no way affiliated with SAP AG. We have made every effort for the content
integrity.  Information used on this site is at your own risk.
ABAP TECHNICAL

SAP Introduction

sap abap faq

sap Tables

SAP Transaction codes

Internal tables

data dictionary

performance tuning

transports & Requests

Sap scripts

Smartforms

lsmw

reports

sap Workflow

module pool/ dialog
programming

table control

user exits

sap memory

abap memory

alv reports

ABAP ADVANCED

IDOC

ALE

BAPI

BADI

RFC


FUNCTIONAL SIDE

Materials Management

FICO

Human Resources

BIW / BW / SEM


Free Documentation
Abap Material

Ale Material

BAPI Material

BC Material

IDOC Material

R/3 Database Management

SAP material

RFC

Transport

Sales & Distribution Material

Basic Data and Function
Material

Basis (BC) Material

Billing Material

CA Material

CATT : Computer Aided Test
Tool

Capacity Evaluation and
leveling Material

Capacity Planning Material

Cross Application Material

Countries

Customer Service Material

Enterpise  Material

Financial / Controlling (FICO)

Internet Time Sheet

Inspection Material

HR Material

Material Management
Material

Payments Material

Payroll Material

Pension Fund

Production Planning and
Control

Plant Maintenance

Quality Management Material

Real Estate Material

SAP material

Wage Types