cancel
Showing results for 
Search instead for 
Did you mean: 

How to pass parameters to custom function type to ABAP Method Database Procedure (AMDP)

jdemiguel1658
Explorer
0 Kudos

Hi experts,

We are working on a BPC Embedded project where we have created a custom function type for planning. Following SAP's instructions, we are using the interface if_rsplfa_srvtype_trex_exec to make sure it runs in Memory. This is very important to us.

In the function type we have defined a parameter of type "Structure", and inside it, another parameter of type "Data Selection". We want to pass the data selection parameter to the sql script but we don't know how to do it as of now, it is completely ignored. The only parameter we are able to see inside the sql script are parameter of type elementary.

This is an example of our if_rsplfa_srvtype_trex_exec~trex_execute method:

method if_rsplfa_srvtype_trex_exec~trex_execute.

data: l_r_sql_script type ref to if_rspls_sql_script,

l_procedure_name type string,

l_t_iobj_param type if_rsr_pe_adapter=>tn_t_iobj_param.

l_r_sql_script = cl_rspls_session_store_manager=>get_sql_script_instance( i_r_store = i_r_store ).

l_r_sql_script->get_parameter_values(

exporting

i_r_param_set = i_r_param_set

i_para_name_for_procedure = 'HANA_PROCEDURE_NAME'

importing

e_procedure_name = l_procedure_name

e_t_iobj_param = l_t_iobj_param ).

l_procedure_name = 'ZCL_RSPLF_CSG_035=>MY_HANA_PROCEDURE'.

r_s_view-view = l_r_sql_script->execute_sql_script(

i_view = i_view

i_t_iobj_param = l_t_iobj_param

i_proc_name = l_procedure_name

i_sql_script_returns_ai = abap_true

i_r_msg = i_r_msg ).

endmethod.

When debugging the function, when it reaches the AMDP method, we don't have access to the data selection parameters defined in the function type. The only parameters we have managed to pass to the amdp method are of type elementary but not data selections.

Does anyone know access the "Data Selection" parameters from the amdp method?

Thanks!

Jorge

Accepted Solutions (0)

Answers (0)