The following name-value pairs are used to run a Managed Reporting My Report.
Request Parameter |
Value |
Description |
---|---|---|
IBIMR_action |
MR_RUN_FEX |
Required. Used to invoke the run action for reports created in the Report Assistant and Graph Assistant tools. |
IBIMR_sub_action |
MR_MY_REPORT |
Required. Used to specify the report type to be run from the Managed Reporting repository. |
IBIMR_fex |
directory/ myreportname. fex |
Required. Used to locate the My Report in the Managed Reporting Repository. The report HREF is normally in the form of directory name (the user ID up to eight characters) for which the report belongs to and an eight character My Report name followed by an extension. For example, user1/carwithd.fex. |
IBIMR_folder |
The My Report HREF in which the report being processed is stored. |
Required. The My Report HREF is usually in the form of the domain HREF followed by a pound sign (#) and a twelve character folder name. For example, untitled/untitled.htm #testk1am7s3i. If the folder name is less than twelve characters, random characters are appended up to twelve characters. |
IBIMR_domain |
The domain HREF in which the report being processed is stored. |
Required. The domain href is normally in the form of an eight character domain directory name, a slash, and an eight character domain file name followed by an extension (for example, domainon/domainon.htm or untitled/untitled.htm). |
IBIMR_random |
A random number |
Required. Used to prevent caching. |
IBIMR_returntype |
Valid values are XML and MRCGI |
Optional. Used to specify the format of the result set. The default is MRCGI. |
//Obtain a random number double random =Math.floor((Math.random()*100000)); //Convert double into a String String rdm = Double.toString(random); //Obtain the path to ibiweb.cfg String cgiLocation = application.getInitParameter("webfocus_client_root")+File.separator+"web" +File.separator+"cgi"; WFApplicationRequest workerReq = new WFApplicationRequest(); WFResponse workerResp = new WFServletResponse( response ); //Instantiate the WFServletVariableTableExtension to add name/value pairs to the request WFServletVariableTableExtension wfSVTExtension = new WFServletVariableTableExtension( request, application ); //Sign-on to Managed Reporting workerReq.addParameter( "IBIMR_action", "MR_SIGNON" ); workerReq.addParameter( "IBIMR_user", "user1" ); workerReq.addParameter( "IBIMR_pass", "user1user1" ); workerReq.addParameter( "IBIMR_returntype", "XML" ); WFWorkerUtil.processRequest( cgiLocation, workerReq, workerResp, wfSVTExtension, null ,null, null ); //Reinitialize the request with the previous response cookies and obtain all MR Domains workerReq.Initialize( workerResp.getCookies() ); workerReq.addParameter( "IBIMR_action", "MR_RUN_FEX" ); workerReq.addParameter("IBIMR_sub_action", "MR_MY_REPORT"); workerReq.addParameter("IBIMR_domain", "untitled/untitled.htm"); workerReq.addParameter("IBIMR_fex", "user1/carwithd.fex"); workerReq.addParameter("IBIMR_folder", "untitled/untitled.htm#cartestv43ax"); workerReq.addParameter("IBIMR_random", rdm); workerReq.addParameter( "IBIMR_returntype", "XML" ); WFWorkerUtil.processRequest( cgiLocation, workerReq, workerResp, wfSVTExtension, null ,null, null );
WebFOCUS |