on 12-01-2016 9:48 AM
I am writing abap code to read the content or a dimension, but I got this error:
"Error in Admin module or a component used by Admin module" what does this error mean ?
My code is as follow:
data:
or_dim type ref to cl_uja_dim,
or_dim_data type ref to if_uja_dim_data,
i_dim_attr type uja_t_attr_name,
w_dim_data type ref to data,
or_data type ref to data,
i_sel type uj0_t_sel,
w_sel type line of uj0_t_sel.
field-symbols:
<i_dim> type standard table,
<w_dim> type any.
data:
v_dim_name type uj_dim_name value 'INDICATORS_RBM',
v_appset_id type uj_appset_id value 'X_RBM'.
data: or_error type ref to cx_uja_admin_error.
try.
create object or_dim
exporting
i_appset_id = v_appset_id
i_dimension = v_dim_name.
catch cx_uja_admin_error into or_error.
message or_error->get_text( ) type 'W'.
cleanup.
endtry.
* Add dim properties to the intrnal table
refresh: i_dim_attr, i_sel.
clear w_sel.
append: 'ID' to i_dim_attr,
'DESCRIPTION' to i_dim_attr.
w_sel-dimension = v_dim_name.
w_sel-attribute = 'CALC'.
w_sel-sign = 'EQ'.
w_sel-option = 'I'.
w_sel-low = 'N'.
append w_sel to i_sel.
* Try read dimesnion according to the selectino criteria
or_dim_data = or_dim.
try.
call method or_dim_data->read_mbr_data
exporting
it_attr_list = i_dim_attr
it_sel = i_sel
importing
er_data = w_dim_data.
catch cx_uja_admin_error into or_error.
message or_error->get_text( ) type 'W'.
cleanup.
endtry.
"I created a z program for Example E: Read Transaction Data via RSDRI ..
I got error CX_UJ_NO_AUTH, it seems I don't have the required permissions ?"
Looks like!
Try the first Example B - absolutely simple and has to work if you have permissions!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
By the way, for some methods to work properly in standalone model you need to set context:
DATA: l_appset_id type uj_appset_id value 'SIM',
l_appl_id type uj_appl_id value 'INPER',
l_user type UJ0_S_USER.
l_user-user_id = 'V.KALININ'.
CALL METHOD cl_uj_context=>set_cur_context
EXPORTING
i_appset_id = l_appset_id
is_user = l_user
i_appl_id = l_appl_id.
Please read this document and compare with you code:
http://go.sap.com/documents/2015/08/6c91e080-5b7c-0010-82c7-eda71af511fa.html#
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
The error is here:
TRY.
lo_measure_dim ?= io_dim.
lo_dim_manager = cl_uja_bpc_admin_factory=>get_dimension_manager(
i_appset_id = lo_measure_dim->d_appset_id
i_application_id = lo_measure_dim->d_appl_id
i_dimension_id = lo_measure_dim->ds_dim-dimension
).
CATCH cx_sy_move_cast_error.
lo_dim_manager = cl_uja_bpc_admin_factory=>get_dimension_manager(
i_appset_id = io_dim->d_appset_id
i_dimension_id = io_dim->ds_dim-dimension
).
ENDTRY.
The code is in the class CL_UJA_MD_QUERY_OPT in the method set_dim
The issue that the lo_dim_manager is initial
Please explain where do you write this code? Is it a badi or...
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
14 | |
4 | |
2 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.