on 05-27-2005 12:19 AM
hi,
this is related to my earlier posting of fetching values from domain.
TABLE NAME IS Z_CODES
FIELD NAME IS CODE
DOMAIN IS CD
under DOMAIN, value range tab -> single values. in that i have few FIXED values around 10 and may likely to change. how to pull these and insert these values in the range table in my program .
any help would be appreciated.
Thanks,
kranthi.
Message was edited by: kranthi kumar
Message was edited by: kranthi kumar
Message was edited by: kranthi kumar
Hi Kranthi,
If you know the domain name, then, you can execute a query on table DD07L. The texts for the values can be retrieved from DD07T, with sy-langu.
DOMNAME - Domain name
AS4LOCAL - Activiation status. Make sure you query with value 'A', for the active version.
VALPOS will determine the order in which the values exist.
If the domain has a range, then, the fields DOMVALUE_L and DOMVALUE_H will be populated.
Cheers,
Rahul
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Kranthi,
I think you can use Function Module
GET_DOMAIN_VALUES
This returns all the fixed values in a domain with the
values description in the VALUES_TAB table parameter.
Hope it helps,
Eyal.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
I tried the function modules, but im unable to pick up the fixed values(under single values in value range tab) from the domain corresponding to that field.
im filling my range table in my program in hard coded way. i want to fill this range table with the values picked up from the domain.
could some one help me on this . your help would be appreciated.
Thanks,
kranthi.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
use one of the following FMs which would give you the domains fixed values.
DDUT_DOMVALUES_GET
SWU_GET_TABLE_TO_DOMNAME
now declare a range table.
ranges: code_r for Z_CODES-code .
now loop thru the resulting table of the FM.
loop at ....
move: fmresult_tab-value to code_r-low ,
'I' to code_r-sign ,
'EQ' to code_r-option .
append code_r .
clear code_r .
endloop .
Hope this helps.
Regards
Raja
Hi,
try fm SWU_GET_TABLE_TO_DOMNAME
regards Andreas
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
> Hi,
>
> try fm SWU_GET_TABLE_TO_DOMNAME
>
>
> regards Andreas
Believe me: DDIF_FIELDINFO_GET is more robust, and if it is to complicated for you, you may also use DDUT_DOMVALUES_GET, although its documentation states that it is obsolete and now should be replaced by DDIF_FIELDINFO_GET.
Greetings
Stephan
User | Count |
---|---|
84 | |
10 | |
10 | |
9 | |
7 | |
6 | |
5 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.