on 04-23-2009 1:28 PM
Hi
Please tell me the ways of accessing database in webdynpro abap(not directly). I am calling Class method for accessing database. As currently I am directly accessing database in my webdynpro application. I have created a class and method for the same.
In my method I want to use select statement which will return table with values to webdynpro application. So for select statement(Calling Method) I need to use my field symbol values as where in clause .
Could anyone please help with example code?
Thanks,
Ujjwal
data: in_line type ref to data.
CREATE DATA in_line LIKE LINE OF <dyn_tab>.
ASSIGN in_line->* TO <dyn_wa>.
You can create a data reference and assign it to a field symbol and change the values. direclty passing field symbols is not possible.
Abhi
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
A Data reference (TYPE REF TO data) is not the same as a field symbol.
You cannot pass field symbols as method parameters and this applies to ABAP OO regardless of Web Dynpro. (use the right forum next time).
What you can do is simply declare the parameters with the same type of the variables the field symbols are pointing to. If it is generic then use DATA as the parameter type (not TYPE REF TO data).
Regards
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Ujwal
You can have type ref to DATA as method parameters and pass it to the method.
Abhi
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
93 | |
10 | |
10 | |
9 | |
9 | |
7 | |
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.