Skip to Content
Author's profile photo Himanshu Sarawagi

Local Web App to execute BEx query (All environment)

Hey All,

Generally any business/Client has 3 or more SAP BW environment in their landscape.

Namely

  1. Development -> Quality -> Production
  2. Development -> Integration -> Quality -> Production

 

Problem Statement : To check some requirement or do some testing or identify an issue/bug, we might need to execute multiple queries in all the system available in landscape.

For the same, we need to either login to BW system and use T-Code RSRT or login to BEx Designer to execute or use the individual portal.

To overcome this, a simple web app can be created using HTML/JavaScript.

Prerequisite : Execute any query in all the environment using BEx designer and note down the initial URL. It should follow the below pattern:

https://APPLICATION_SERVER/irj/servlet/prt/portal/prtroot/pcd!3aportal_content!2fcom.sap.pct!2fplatform_add_ons!2fcom.sap.ip.bi!2fiViews!2fcom.sap.ip.bi.bex?QUERY=BEx_Technical&VARIABLE_SCREEN=X&DUMMY=1
  • APPLICATION_SERVER= This will be the Server URL for your system.
  • BEx_Technical = Your BEx Technical Name.

Lets build the HTML page or Web-App.

  1. Copy the below code and paste in a Notepad and save as “xyz.htm”.
  2. Now insert your development application server’s path as noted from above section.

Now its ready to use for development environment.

You can add otherĀ environments as per your landscape.

  1. Copy function myDev() to myProd() and so on.
  2. Add more button for new functions .i.e myProd() etc.
<!DOCTYPE html>
<html>
<body>

<script>

function myDev() {

var url=document.getElementById("querytext").value;

var appended1="https://INSERT_DEVELOPMENT_APPLICATION_SERVER/irj/servlet/prt/portal/prtroot/pcd!3aportal_content!2fcom.sap.pct!2fplatform_add_ons!2fcom.sap.ip.bi!2fiViews!2fcom.sap.ip.bi.bex?QUERY=".concat(url);

var appended = appended1.concat("&VARIABLE_SCREEN=X&DUMMY=1");

window.open(appended);

}

</script>

<form >
  <br><br>
  Type the BEx Query technical name to open : &nbsp;&nbsp;
  <input id="querytext" type="text" size="35">
  <br>
  <br>

  <button onclick="myDev()"> Dev : B3B </button> 

</form> 

</body>
</html>

 

Thanks,

Himanshu Sarawagi

 

Assigned Tags

      Be the first to leave a comment
      You must be Logged on to comment or reply to a post.