Thursday, 10 July 2014

LDB: Logical data Base(Single Node)

Logical Data Base(LDB):  Logical data base can be created in Tx- SLDB or SE36 . The advantage of using LDB is that it provides an automatically selection screen and the data selection process when added to a report program. some events that occurs in LDB are INIT, PUT & GET. Once the LDB is created, it can be added to a report program in the Attributes section or inside the program by calling the standard function module 'LDB_PROCESS'. 
-----------------------------------------------------------------------------------------------------------------------------------

Step1. These are the entries present in SCARR table.


Step2. To Create LDB go to TX- SE36 or SLDB.






OR






Step3. Provide a name ans select structure radio button and then click on Create button.





















Step4. Provide short text and continue.
























Step5. So we need to create an LDB on SCARR table, mention the root node as : SCARR , text and Under Node type SCARR. The root node name and the database table name should be same. At last click on Create button.





















Step6. So node SCARR is created. Now lets create a selection screen element. So click on the Selections button.















Step7. YES to continue.

















Step8. Select both the check boxes and click on Transfer.



















Step9. Here some commented code appears for the Select-option statement based on the primary key of the table. Un-comment the line and provide a select-option name. Here we have provides name as : S_CARRID. Activate it and go back. 






















Step10. Node is defined, Selection-screen is defined. For the data selection process based on the selection screen elements, click on the Source code button.













Step11.  YES to continue.

















Step12. Some automatically created includes. Double click on the second include.













Step13. For the node SCARR selection process, double click on the first include.















Step14. the below screen appears with some commented code. And also PUT event.























Step15. Un comment the code and put a select and endselect statement. Activate and go back. 

























Step16. Go to Tx- SE38 and create a report.



















Step17. Under the attributes section, mention the above created LDB name and continue.























Step18. Just write the below code and execute the report. Here we use the GET event. The NODES statement triggers the LDB and The PUT events forwards the data from the LDB progrm to the GET event of the report.















Step19. The selection appears as a result of the LDB. Execute it.









Step20. All the records are transferred from the LDB PUT event to the GET event of the report & the records are displayed.

Step21. Execution with single input.








Step22.O/P.













Step23. Execution with range I/P.









Step24. O/P.

















---------------------------------------------------------------------------------------------------------------------------------

No comments:

Comments system

Disqus Shortname