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.
For chaining I normally use the standard method - populating list boxes /combo boxes using data sources; then I get the GUI to chain them together.
However, I have a situation where I want one master combo box to influence two separate chains. ie: a country selector to influence the geography hierarchy (state + territory) separately to the products (Brand) available in that country.
I've successfully done this within DEV Studio by leaving the country+state+territory boxes as simple data source based chaining, then the other hierarchy uses a procedure to populate the brand list. I've explicitly coded the onchange event handlers of the country lists to use the method I've seen posted previously:
This works beatifully for me in DEV Studio, but when I deploy it to our server, it won't work. I've done some debugging using a web debugging proxy tool (Charles) which actually shows that when the procedures are called to populate the Brand list, no parameter is passed - ie: the Country parameter do not get passed through (This is included in the FEX as below):
-DEFAULT &COUNTRY_NAME=FOC_NONE;
TABLE FILE DIM_PRODUCT
PRINT DST.BRAND_NAME
BY BRAND_NAME
WHERE (COUNTRY_NAME EQ &COUNTRY_NAME);
ON TABLE SET HOLDLIST PRINTONLY
ON TABLE PCHOLD FORMAT XML
END
I've done the same debugging locally and it does do it properly.
Any ideas? Could it be a server setting that is different to my local? Could it be a WF version issue?
Local environment: WF 7.6.6 Server: WF 7.6.4
We are developing & deploying into Managed Reporting.
Any help greatly appreciated!
Thanks, SteveThis message has been edited. Last edited by: Kerry,
In this instance (and most others - I prefer to control the flow) I would be inclined to use fexes to populate all of the combos, using -
WHERE COUNTRY EQ '&Country' in fexes for combos 2, 3 and 4 (State, Territory and Brand) WHERE STATE EQ '&State' in fexes for combo 3 (Territory)
That way you get exactly what you want using standard WF and without having to get into the JavaScript.
For debugging, I have another copy of ibigbl.js called ibigbl_debug.js which is a direct copy of the original with a change to the JS file reference for ibirls.js (ibirls_debug.js would you believe? ). In the file ibirls_debug.js I insert alerts where and when I need them. Any HTML page I create can then be debugged just by changing the ibigbl.js reference.
T
In FOCUS since 1986
WebFOCUS Server 8.2.01M, thru 8.2.07 on Windows Svr 2008 R2
WebFOCUS App Studio 8.2.06 standalone on Windows 10
Posts: 5694 | Location: United Kingdom | Registered: April 08, 2004
I've tried your suggestion of making all of these parameters (actually list boxes) get populated from a FEX. I've got the relevant FEXs with appropariate WHERE clauses similar to the ones you had (although without the quotes around the amper variables because the list boxes allow multiple selection).
I now don't have any onchange events and nothing is chained via the GUI. Now, all of the list boxes work independently. Have I missed something out?
Yes, you still have to chain all four combos via the GUI or manually code the array etc. Better to do it via the GUI unless you know what components you need to code.
One of the processes that occurs in ibirls.js is to identify each combo and add an onchange event which calls a function within ibirls.js controlling the population of the combos. By adding the chained array code, this function knows that the combo is chained and will furnish the required variable(s) from predecessor combo(s).
T
In FOCUS since 1986
WebFOCUS Server 8.2.01M, thru 8.2.07 on Windows Svr 2008 R2
WebFOCUS App Studio 8.2.06 standalone on Windows 10
Posts: 5694 | Location: United Kingdom | Registered: April 08, 2004
You're coming to Summit, SJ? T and I are giving a demo of just this very issue, on Tuesday afternoon at the Focal Point session, and we'll be giving you the code to actually run. its not as gui-simple as it would appear, but its not hard either.
In Focus since 1979///7706m/5 ;wintel 2008/64;OAM security; Oracle db, ///MRE/BID
Posts: 3811 | Location: Manhattan | Registered: October 28, 2003
Is this double chain scenario possible using the GUI
Simple answer is no, but a quick and dirty way of doing this is to have a second, hidden, combo for Country and chain that to Brand. Add an onchange event to the second hidden combo to set the selectedIndex value to that from the visible one.
I'm sure that I posted something very similar (if not the same) a while ago. See if you can find that.
T
In FOCUS since 1986
WebFOCUS Server 8.2.01M, thru 8.2.07 on Windows Svr 2008 R2
WebFOCUS App Studio 8.2.06 standalone on Windows 10
Posts: 5694 | Location: United Kingdom | Registered: April 08, 2004
Susannah - unfortunately I won't be at Summit - its a bit of a hike from Australia. Maybe I'll try and plan it into the budget for next year.
Tony - I tried the scenario you described also (ie: having a hidden combo for country to mirror the main one then chaining off this), however when I set the value in the second one I can't force the chain to fire.
The frustrating thing is that I have everything functioning perfectly in my local WF 7.6.6 installation, but when I deploy to 7.6.4 it doesn't work.
Just for clarity, this is what I have done locally that actually works:
* Country, State, Territory lists populated from data sources, then chained via the GUI. * Brand list populated using a FEX, with &COUNTRY_NAME in the WHERE clause * Code added to the onchange event handler of the Country list to call "populateDynamicCtrl" on the brand list * When debugging on local, I can actually see that the country name variable is passed into the FEX; whereas on the test/prod servers (7.6.6) the variable does not go into the FEX.
(BTW, before posting I did a bunch of research on the forum and I'm sure I got the above idea from one of your posts Tony - thanks)
I've decided to deploy for the time being without the chain from country to brand, but will perservere and look into upgrading the prod box to 7.6.6 at some stage.
Here's some demo code that I wrote ages ago for a female member of the forum (whose initals are SJ funnily enough!). It was written in 7.6.4 with a lot of (but not all) extraneous code stripped out.
Hopefully it should show you what I mean - it does work in later versions.
-* SJ_Combo1.fex
TABLE FILE CENTORD
SUM FST.YEAR
BY YEAR
ON TABLE PCHOLD FORMAT XML
END
-RUN
-* SJ_Combo2.fex
-DEFAULT &Year = 'FOC_NONE'
TABLE FILE CENTORD
SUM FST.MONTH
BY MONTH
WHERE YEAR EQ &Year
ON TABLE PCHOLD FORMAT XML
END
-RUN
-* SJ_Combo3.fex
-DEFAULT &Year1 = 'FOC_NONE'
TABLE FILE CENTORD
SUM FST.QUARTER
BY QUARTER
WHERE YEAR EQ &Year1
ON TABLE PCHOLD FORMAT XML
END
-RUN
-* SJ_Combo4.fex
-DEFAULT &Year1 = 'FOC_NONE'
-DEFAULT &Quarter = 'FOC_NONE'
TABLE FILE CENTORD
SUM FST.ORDER_DATE
BY ORDER_DATE
WHERE YEAR EQ &Year1
WHERE QUARTER EQ &Quarter
ON TABLE PCHOLD FORMAT XML
END
-RUN
Hope it helps
T
In FOCUS since 1986
WebFOCUS Server 8.2.01M, thru 8.2.07 on Windows Svr 2008 R2
WebFOCUS App Studio 8.2.06 standalone on Windows 10
Posts: 5694 | Location: United Kingdom | Registered: April 08, 2004