Focal Point Banner


As of December 1, 2020, Focal Point is retired and repurposed as a reference repository. We value the wealth of knowledge that's been shared here over the years. You'll continue to have access to this treasure trove of knowledge, for search purposes only.

Join the TIBCO Community
TIBCO Community is a collaborative space for users to share knowledge and support one another in making the best use of TIBCO products and services. There are several TIBCO WebFOCUS resources in the community.

  • From the Home page, select Predict: WebFOCUS to view articles, questions, and trending articles.
  • Select Products from the top navigation bar, scroll, and then select the TIBCO WebFOCUS product page to view product overview, articles, and discussions.
  • Request access to the private WebFOCUS User Group (login required) to network with fellow members.

Former myibi community members should have received an email on 8/3/22 to activate their user accounts to join the community. Check your Spam folder for the email. Please get in touch with us at community@tibco.com for further assistance. Reference the community FAQ to learn more about the community.


Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     [SOLVED] drill down - execute two procedures

Read-Only Read-Only Topic
Go
Search
Notify
Tools
[SOLVED] drill down - execute two procedures
 Login/Join
 
Gold member
posted
Dear all,

May be you can advise me how to update 2 frames (run 2 focexecs) on drill down? I have 3 graph on page and on selecting some field in first, like to update 2 rest graphs.

thank yo in advance!

This message has been edited. Last edited by: <Kathryn Henning>,


Wf7704/WF8,Win64/32
 
Posts: 68 | Registered: February 20, 2004Report This Post
Platinum Member
posted Hide Post
Yo could try the following technique....ie. in this case drill-down to xxxxx if they select HTML format, or drill-down to yyyyy if they select Excel format Xpass
TYPE=DATA,
DRILLMENUITEM='HTML',
FOCEXEC=xxxxx(SERV_LINE=N2 \
TEAM_NAME=N3 \
TBL_REQUEST='&TBL_REQUEST' \
KPI_NUM=N8 \
OUTPUT='HTML' ),
DRILLMENUITEM='Excel',
FOCEXEC=yyyyy(SERV_LINE=N2 \
TEAM_NAME=N3 \
TBL_REQUEST='&TBL_REQUEST' \
KPI_NUM=N8 \
OUTPUT='EXL2K' ),


_______________________
*** WebFOCUS 8.1.05M ***
 
Posts: 196 | Location: London, UK | Registered: December 06, 2005Report This Post
Gold member
posted Hide Post
Thank you Ian, I know and use in other places this multi-drill technique.

But I need on press of value to update both graphs - it's a bit other thing. With one click.

is it impossible?


Wf7704/WF8,Win64/32
 
Posts: 68 | Registered: February 20, 2004Report This Post
Virtuoso
posted Hide Post
The concept of a drill-down involves well, "drilling" from a high-level or summarized data representation "down" to the detail rows that make up that particular data piece and by design, you can have only one single target for the action taken.

To try and achieve what you want it may require using a custom JavaScript function as the target of your drill-down and within it create the calls to each graph procedure targeting each of your iframes.

Something like the following (very high-level and simplistic):

1) Create the drilldown call to a custom JS function passing whatever parameters make sense:

...
TYPE=DATA, COLUMN=N5, JAVASCRIPT=runGraphs(N5), $
...


2) Define your JS function either in a file you can reference via JSURL or perhaps embedded within HTMLFORM. You'll have to play with that.

// This is *not* valid JS code ... just a concept!
function runGraphs(value) {
   var iframe1 = document.getElementById('iframe1');  // iframe for Graph 1
   var iframe2 = document.getElementById('iframe2');  // iframe for Graph 2

   if(iframe1) {
      // Build URL to call WF graph procedure passing "value" as a valid parameter expected by the .fex
      // URL must represent a valid WFServlet call depending on where the .fex is located (Server or MRE)

      var graphURL1 = '/ibi_apps/WFServlet?IBIF_ex=mygraph1.fex&PARAM1=' || value;
      // "Run" request in iframe1
      iframe1.src = graphURL1;
   }

   if(iframe2) {
      // Build URL to call WF graph procedure passing "value" as a valid parameter expected by the .fex
      // URL must represent a valid WFServlet call depending on where the .fex is located (Server or MRE)

      var graphURL2 = '/ibi_apps/WFServlet?IBIF_ex=mygraph2.fex&PARAM1=' || value;
      // "Run" request in iframe2
      iframe2.src = graphURL2;
   }

}



As I said, that's very simplistic but it's how I would probably start at playing when implementing a similar solution. Hopefully the concept makes sense and you can follow it to solve your need.



Prod/Dev: WF Server 8008/Win 2008 - WF Client 8008/Win 2008 - Dev. Studio: 8008/Windows 7 - DBMS: Oracle 11g Rel 2
Test: Dev. Studio 8008 /Windows 7 (Local) Output:HTML, EXL2K.
 
Posts: 1533 | Registered: August 12, 2005Report This Post
Expert
posted Hide Post
You could DRILL DOWN to a single fex which, in turn, -INCLUDEs two, or more, fexes. That would, essentially, "run 2 focexecs from a single drill down"...
 
Posts: 3132 | Location: Tennessee, Nashville area | Registered: February 23, 2005Report This Post
Gold member
posted Hide Post
Doug, let's say I went to FEX1 (what means I updating graph_1 in iframe_1). How to ask from this fex to update graph_2 in iframe2 on same page? Possible? With what kind of INCLUDE?

It looks solution form njsden is the right one and it is not possible to do just by WF.


Wf7704/WF8,Win64/32
 
Posts: 68 | Registered: February 20, 2004Report This Post
Virtuoso
posted Hide Post
That's true Doug, but the output of such procedure(s) will still be constrained to a single target window or iframe.

Having 2 separate iframes loading independent results as Piter wants upon clicking a drill-down link would require 2 individual requests to be triggered concurrently which is not supported by the current implementation of FOCEXEC for drilldowns, hence the need for JavaScript.

Perhaps there is a more straightforward way to accomplish the very same ...

Piter, do you really need your graphs running in individual iframes? How about having them both in a single HTML document separated in individual DIV's which you can style at will? That way you can use a single procedure as Doug suggests, within which you'd produced both graphs holding them in HTMTABLE format and then putting them together via -HTMLFORM.



Prod/Dev: WF Server 8008/Win 2008 - WF Client 8008/Win 2008 - Dev. Studio: 8008/Windows 7 - DBMS: Oracle 11g Rel 2
Test: Dev. Studio 8008 /Windows 7 (Local) Output:HTML, EXL2K.
 
Posts: 1533 | Registered: August 12, 2005Report This Post
Gold member
posted Hide Post
njsden, sorry for saying that, but I am too "dummy" - I have tried several times, but was not able to put different graphs to different DIV's. This can be ideal solution for me, but I have not find a way to do it... Is there any simple example?


Wf7704/WF8,Win64/32
 
Posts: 68 | Registered: February 20, 2004Report This Post
Virtuoso
posted Hide Post
Here's a very basic example using the CAR table:

-DEFAULT &P_COUNTRY='ENGLAND';

-* Graph 1
GRAPH FILE CAR
-* Created by Advanced Graph Assistant
SUM CAR.BODY.DEALER_COST
CAR.BODY.RETAIL_COST
BY CAR.COMP.CAR
WHERE CAR.ORIGIN.COUNTRY EQ '&P_COUNTRY';
ON GRAPH HOLD AS HGRAPH1 FORMAT HTMTABLE
ON GRAPH SET HTMLENCODE ON
ON GRAPH SET GRAPHDEFAULT OFF
ON GRAPH SET VZERO OFF
ON GRAPH SET HAXIS 770
ON GRAPH SET VAXIS 405
ON GRAPH SET UNITS PIXELS
ON GRAPH SET LOOKGRAPH VBAR
ON GRAPH SET GRMERGE ADVANCED
ON GRAPH SET GRMULTIGRAPH 0
ON GRAPH SET GRLEGEND 0
ON GRAPH SET GRXAXIS 1
ON GRAPH SET GRAPHSTYLE *
setTemplateFile("/images/tdg/template/IBISouthWestern.txt");
setTextString(getTitle(),"Sales in &P_COUNTRY");
setDisplay(getTitle(),true);
ENDSTYLE
END
-RUN

-* Graph 2
GRAPH FILE CAR
-* Created by Advanced Graph Assistant
SUM CAR.BODY.SALES
BY CAR.COMP.CAR
WHERE CAR.ORIGIN.COUNTRY EQ '&P_COUNTRY';
ON GRAPH HOLD AS HGRAPH2 FORMAT HTMTABLE
ON GRAPH SET HTMLENCODE ON
ON GRAPH SET GRAPHDEFAULT OFF
ON GRAPH SET VZERO OFF
ON GRAPH SET HAXIS 770
ON GRAPH SET VAXIS 405
ON GRAPH SET UNITS PIXELS
ON GRAPH SET LOOKGRAPH PIESINGL
ON GRAPH SET GRMERGE ADVANCED
ON GRAPH SET GRMULTIGRAPH 0
ON GRAPH SET GRLEGEND 1
ON GRAPH SET GRXAXIS 0
ON GRAPH SET GRAPHSTYLE *
setTemplateFile("/images/tdg/template/IBISouthWestern.txt");
setDepthRadius(5); 
setPieDepth(10);
setPieFeelerTextDisplay(1); 
setTransparentBorderColor(getChartBackground(),true); 
setPlace(true);
ENDSTYLE
END
-RUN

-HTMLFORM BEGIN
<!DOCTYPE html>
<html lang="en"><head><title>Sales Charts</title>
<style type="text/css">
#pnGraph1 { float: left; }
</style>
</head>
<body>
<div id='pnGraph1'>!IBI.FIL.HGRAPH1;</div>
<div id='pnGraph2'>!IBI.FIL.HGRAPH2;</div>
</body>
</html>
-HTMLFORM END



Of course you can make the charts much sexier using appropriate styling, along with some CSS to make sure your DIV elements get positioned as you need them.

This message has been edited. Last edited by: njsden,



Prod/Dev: WF Server 8008/Win 2008 - WF Client 8008/Win 2008 - Dev. Studio: 8008/Windows 7 - DBMS: Oracle 11g Rel 2
Test: Dev. Studio 8008 /Windows 7 (Local) Output:HTML, EXL2K.
 
Posts: 1533 | Registered: August 12, 2005Report This Post
Gold member
posted Hide Post
As usual - nice example, big Thank you!


Wf7704/WF8,Win64/32
 
Posts: 68 | Registered: February 20, 2004Report This Post
  Powered by Social Strata  

Read-Only Read-Only Topic

Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     [SOLVED] drill down - execute two procedures

Copyright © 1996-2020 Information Builders