on 08-25-2008 6:38 AM
hi
please tell me how to retrieve data from database without using any FM (function module). i want to tap the data into an internal table and then show it through a table( i.e U I element).
Hi,
Please follow the below steps.
1.Create a context node with attributes from structure as you required.
2.Go to DOININT method use 'Web Dynpro ABAP Code Wizard' from application tool bar to read the context.
3. Write select query and move selected data into internal table.
4. Now bind internal table to context node.
5. go to view drag insert table UI element and then create binding with context node.
Please see below articles and examples.
WDR_TEST_TABLE
WDR_TEST_TREE
WDR_TEST_UI_ELEMENTS
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Vishwdeep,
Well there are different ways of getting data from database table but all the ways have only one commant i.e select(i am talking explicitaly about webdynpro framework)
Solution 1) U create internal table in any user defiend of method of view or in hooks methods and write select query in that method .U will get data in ITAB as webdynpro abap framework is embedded in abap workbench(not like java webdynpro).
Solution 2)As per MVC pattern you should not write select queries in your view methods instead write it down in class/methods and use that class as assistance class .
Thease are the two ways that you can get data in webdynrpo.
If any query feel free to ask.
regards
PG
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
hi,
You can directly use your select statement in WDA. but it is advisable to use FM because of modularization.
Yogesh N
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
87 | |
10 | |
10 | |
10 | |
7 | |
6 | |
6 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.