Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

logical data base

Former Member
0 Likes
528

hai...

What are logical databases? What are the advantages/disadvantages of logical databases?

thanks

pavan

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
487

Hi,

<u><b>Logical Databases</b></u>

Logical databases are special ABAP programs that read data from database tables. They are

used by executable (type 1) programs. At runtime, you can regard the logical database and the

executable program (reports) as a single ABAP program, whose processing blocks are called by

the runtime environment in a particular, pre-defined sequence.

You edit logical databases using a tool within the ABAP Workbench, and link them to executable

programs (reports) when you enter the program attributes. You can use a logical database with

any number of executable programs (reports). From Release 4.5A, it is also possible to call

logical databases on their own.

<u><b>Structure of a Logical Database</b></u>

Structure

The structure of a logical database determines the database tables which it can access. It adopts

the hierarchy of the database tables defined by their foreign key relationships. This also controls

the sequence in which the tables are accessed.

Selection Part

The selection part of the logical database defines input fields for selecting data. The runtime

environment displays these on the selection screen when you run an executable program linked

to the logical database. The corresponding fields are also available in the ABAP program,

allowing you, for example, to change their values to insert default values on the selection screen.

Database Program

The database program of a logical database is a container for special subroutines, in which the

data is read from the database tables. These subrotuines are called by the reporting processor in

the runtime environment in a predefined sequence.

<u><b>Uses of Logical Databases</b></u>

The main use of logical databases is to make the code that accesses data in database tables

reusable. SAP supplies logical databases for all applications. These have been configured for

optimal performance, and contain further functions such as authorization checks and search

helps. It is appropriate to use logical databases whenever the database tables you want to read

correspond largely to the structure of the logical database and where the flow of the system

program (select - read - process - display) meets the requirements of the application.

Regards,

Bhaskar

4 REPLIES 4
Read only

former_member196280
Active Contributor
0 Likes
487

Advantages of logical data base.

No need of query to retrive it.

Disadvantages.

Performance in some cases.

Regards,

Sairam

Read only

Former Member
0 Likes
487

Hi

A logical database is a special ABAP/4 program which combines the contents of certain database tables. You can link a logical database to an ABAP/4 report program as an attribute. The logical database then supplies the report program with a set of hierarchically structured table lines which can be taken from different database tables.

LDB offers an easy-to-use selection screens. You can modify the pre-generated selection screen to your needs. It offers check functions to check whether user input is complete, correct, and plausible. It offers reasonable data selections. It contains central authorization checks for data base accesses. Enhancements such as improved performance immediately apply to all report programs that use the logical database.

Less coding s required to retrieve data compared to normal internel tables.

Tables used LDB are in hierarchial structure.

Mainly we used LDBs in HR Abap Programming.

Where all tables are highly inter related so LDBs can optimize the performance there.

Check this Document. All abt LDB's

https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.highlightedcontent?documenturi=...

GO THROUGH LINKS -

http://www.sap-basis-abap.com/saptab.htm

http://help.sap.com/saphelp_nw04/helpdata/en/9f/db9bfa35c111d1829f0000e829fbfe/content.htm

http://help.sap.com/saphelp_nw04/helpdata/en/9f/db9b5e35c111d1829f0000e829fbfe/frameset.htm

http://help.sap.com/saphelp_nw04/helpdata/en/c6/8a15381b80436ce10000009b38f8cf/frameset.htm

/people/srivijaya.gutala/blog/2007/03/05/why-not-logical-databases

www.sapbrain.com/FAQs/TECHNICAL/SAP_ABAP_Logical_Database_FAQ.html

www.sap-img.com/abap/abap-interview-question.htm

www.sap-img.com/abap/quick-note-on-design-of-secondary-database-indexes-and-logical-databases.htm

http://help.sap.com/saphelp_nw04/helpdata/en/9f/db9b5e35c111d1829f0000e829fbfe/content.htm

http://help.sap.com/saphelp_nw2004s/helpdata/en/9f/db9bb935c111d1829f0000e829fbfe/content.htm

Gothru the blog which provides info on LDB's:

/people/srivijaya.gutala/blog/2007/03/05/why-not-logical-databases

<b>Reward points for useful Answers</b>

Regards

Anji

Read only

Former Member
0 Likes
487

Hi,

Logical Databases are special ABAP programs that retrieve data and make it available to application programs.

Use of LDB – is used to read data from database tables by linking them to executable ABAP programs.

There are the events used for Logical Database

Two Events –

1)GET - This is the most important event for executable programs that use a logical database. It occurs when the logical database has read a line from the node <table> and made it available to the program in the work area declared using the statement NODES <table>. The depth to which the logical database is read is determined by the GET statements

2)PUT - The PUT statement directs the program flow according to the structure of the logical database.

Thanks,

Sandeep.

Read only

Former Member
0 Likes
488

Hi,

<u><b>Logical Databases</b></u>

Logical databases are special ABAP programs that read data from database tables. They are

used by executable (type 1) programs. At runtime, you can regard the logical database and the

executable program (reports) as a single ABAP program, whose processing blocks are called by

the runtime environment in a particular, pre-defined sequence.

You edit logical databases using a tool within the ABAP Workbench, and link them to executable

programs (reports) when you enter the program attributes. You can use a logical database with

any number of executable programs (reports). From Release 4.5A, it is also possible to call

logical databases on their own.

<u><b>Structure of a Logical Database</b></u>

Structure

The structure of a logical database determines the database tables which it can access. It adopts

the hierarchy of the database tables defined by their foreign key relationships. This also controls

the sequence in which the tables are accessed.

Selection Part

The selection part of the logical database defines input fields for selecting data. The runtime

environment displays these on the selection screen when you run an executable program linked

to the logical database. The corresponding fields are also available in the ABAP program,

allowing you, for example, to change their values to insert default values on the selection screen.

Database Program

The database program of a logical database is a container for special subroutines, in which the

data is read from the database tables. These subrotuines are called by the reporting processor in

the runtime environment in a predefined sequence.

<u><b>Uses of Logical Databases</b></u>

The main use of logical databases is to make the code that accesses data in database tables

reusable. SAP supplies logical databases for all applications. These have been configured for

optimal performance, and contain further functions such as authorization checks and search

helps. It is appropriate to use logical databases whenever the database tables you want to read

correspond largely to the structure of the logical database and where the flow of the system

program (select - read - process - display) meets the requirements of the application.

Regards,

Bhaskar