cancel
Showing results for 
Search instead for 
Did you mean: 

Calling a BW Bex Query in Web Dynpro ABAP

Former Member
0 Kudos

Hi Team,

I'm trying to call a BW Bex query in my web dynpro screen. The Web Dynpro is written in our ERP (ECC 6.0) system. I have specific parameters and values in my web dynpro context which I want to pass to a BW query and then display the actual query in my web dynpro. I found an element BIApplicationFrame but don't know if that is the correct way to display the query. Some questions:

1) How do I pass the username/password for the BW system in the Web Dynpro written in ERP?

2) How do I pass the parameters to the query

3) How is the security and roles managed. The web dynpro is enables as an iView in the SAP Portal.

Thanks much for your guidance.

Regards

Sanjay

Accepted Solutions (0)

Answers (3)

Answers (3)

petr_stribrny
Explorer
0 Kudos

Hi,

I'm dealing with the same issue. The question is marked as answered, but the solution has not been published.

Thanks for an update,

Petr

Former Member
0 Kudos

Petr:

I managed to pass the selection variables to the query through BIApplicationFrame. This is how I did it.

1) Added the BIApplicationFrame UI element to the View of the Webdynpro application and named it ZBIQUERY with the following properties relevant to my system.

- dataProviderStateName property is set to my query name which is 'ZPUR_M02_Q08'

- dataProviderStateType is set to 'Query'.

- server is set to 'housapdbw.noble.cc:8000'

- templateId is set to 'ZPUR_M02_W02'

- variableScreen is Unchecked.

2) Added two attributes to the view under the attributes tab. They are

M_APPL_FRAME RefTo CL_WD_BIAPPLICATION_FRAME

M_METHOD_HANDLER RefTo IF_WD_BI_APPLFRAME_METHOD_HNDL

3) Then add the following code in the method WDDOMODIFYVIEW.

data:

lt_parameters type if_wd_bi_applframe_method_hndl=>tt_name_value,

ls_parameters type if_wd_bi_applframe_method_hndl=>t_name_value.

define add_parameter.

clear ls_parameters.

ls_parameters-name = &1.

ls_parameters-value = &2.

append ls_parameters to lt_parameters.

end-of-definition.

if first_time = abap_true.

wd_this->m_appl_frame ?= view->get_element( 'ZBIQUERY' ).

wd_this->m_method_handler ?= wd_this->m_appl_frame->_method_handler.

endif.

  • Please note that the selection screen on my query has Select-options and its name is

  • XREF_NUM0001. I am passing a value of '11111' to it as shown below.

refresh lt_parameters.

add_parameter 'CMD' 'PROCESS_VARIABLES'. " This is for Execute button

add_parameter 'SUBCMD' 'VAR_SUBMIT'. " This one also for Execute Button

add_parameter 'VAR_NAME_1' 'XREF_NUM0001'. " Name of my select-option

add_parameter 'VAR_OPERATOR_1' 'EQ'.

add_parameter 'VAR_SIGN_1' 'I'.

add_parameter 'VAR_VALUE_LOW_EXT_1' '11111'. " Value for my select-option

wd_this->m_method_handler->execute_command( lt_parameters ).

endif.

The above code needs to be added before the view is called in th is method.

Hope this helps.

Krishna Muppavarapu

petr_stribrny
Explorer
0 Kudos

Hi Krishna,

Thanks for your example. I'll check it out as soon as needed again. Unfortunatelly, since I am not the requester I am not allowed to give you points. If you know the way how to do that, pleasae let me know. In the other case, thank you for your help.

Best regards,

Petr

Former Member
0 Kudos

I am trying to do the samething now. Can you tell how you did it please?

Thanks

Krishna

Former Member
0 Kudos

Was able to figure it out on my own. Thanks