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     Group By using a user selected variable

Read-Only Read-Only Topic
Go
Search
Notify
Tools
Group By using a user selected variable
 Login/Join
 
Member
posted
I am new to WebFOCUS so hopefully this is an easy one.

I want to design a set of reports where the user selects what field they want the report to Group on. So I want to present the users two sets of prompts - one they can use to filter the data and the other they can select the Group by field. Depending on what they pick the report will show data grouped by that field, sub totals, page breaks etc.

Am I right in assuming it can be done quite easily in WebFOCUS.

Thanks,
Raj
 
Posts: 15 | Registered: June 18, 2007Report This Post
Expert
posted Hide Post
Raj,

It can be done using variables and Dialogue Manager. I'm not sure how easy it would be for a brand-new user. There should be an example program in one of the IBI demo directories that does exactly what you want. Just run the demos and all the links and see if something strikes you as similar to what you are wanting to do.

You might want to update your profile signature with the WebFOCUS products that you are using, the releases and the platforms.


Ginny
---------------------------------
Prod: WF 7.7.01 Dev: WF 7.6.9-11
Admin, MRE,self-service; adapters: Teradata, DB2, Oracle, SQL Server, Essbase, ESRI, FlexEnable, Google
 
Posts: 2723 | Location: Ann Arbor, MI | Registered: April 05, 2006Report This Post
Member
posted Hide Post
Thanks Ginny!

I will have access to advanced WebFOCUS developers in the near future. I didn't want to promise a functionality to our stakeholders before verifying it first.
 
Posts: 15 | Registered: June 18, 2007Report This Post
Platinum Member
posted Hide Post
Hi Raj

Yes we do that all the time. You can create very complex and dynamic reports like that.

Here is a simple example to get you started.

Assume that GROUPBY is coming from a multiple select combobox...

-SET &GROUPBY='MODEL, COUNTRY';
-SET &GETMODEL=IF POSIT(&GROUPBY, &GROUPBY.LENGTH, 'MODEL', 5, 'I2') GT 0 THEN 'BY MODEL' ELSE '';
-SET &GETCOUNTRY=IF POSIT(&GROUPBY, &GROUPBY.LENGTH, 'COUNTRY', 7, 'I2') GT 0 THEN 'BY COUNTRY' ELSE '';

TABLE FILE CAR
SUM SALES
&GETMODEL
&GETCOUNTRY
END

-SET &GROUPBY='MODEL';
-SET &GETMODEL=IF POSIT(&GROUPBY, &GROUPBY.LENGTH, 'MODEL', 5, 'I2') GT 0 THEN 'BY MODEL' ELSE '';
-SET &GETCOUNTRY=IF POSIT(&GROUPBY, &GROUPBY.LENGTH, 'COUNTRY', 7, 'I2') GT 0 THEN 'BY COUNTRY' ELSE '';

TABLE FILE CAR
SUM SALES
&GETMODEL
&GETCOUNTRY
END

-SET &GROUPBY='COUNTRY';
-SET &GETMODEL=IF POSIT(&GROUPBY, &GROUPBY.LENGTH, 'MODEL', 5, 'I2') GT 0 THEN 'BY MODEL' ELSE '';
-SET &GETCOUNTRY=IF POSIT(&GROUPBY, &GROUPBY.LENGTH, 'COUNTRY', 7, 'I2') GT 0 THEN 'BY COUNTRY' ELSE '';

TABLE FILE CAR
SUM SALES
&GETMODEL
&GETCOUNTRY
END



Jodye


WF 8.0.0.5M
 
Posts: 246 | Location: Montreal, QC, Canada | Registered: October 01, 2003Report This Post
Virtuoso
posted Hide Post
Great example Jodye. I wouldn't even go that complicated. I just have simple drop-downs. I use multiple drop-down boxes if they want multiple sorts rather than a multi-select. It seems to work better when you also have drill-downs in the report. Anyway, this allows you to simply substitute and &var wherever the BY field would be used:

TABLE FILE CAR
PRINT CAR
BY &SORT1 PAGE-BREAK
ON &SORT1 SUBTOTAL
END


Regards,

Darin



In FOCUS since 1991
WF Server: 7.7.04 on Linux and Z/OS, ReportCaster, Self-Service, MRE, Java, Flex
Data: DB2/UDB, Adabas, SQL Server Output: HTML,PDF,EXL2K/07, PS, AHTML, Flex
WF Client: 77 on Linux w/Tomcat
 
Posts: 2298 | Location: Salt Lake City, Utah | Registered: February 02, 2007Report 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     Group By using a user selected variable

Copyright © 1996-2020 Information Builders