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     [CLOSED] Guided Ad Hoc - Select Year and Month separately from one field?

Read-Only Read-Only Topic
Go
Search
Notify
Tools
[CLOSED] Guided Ad Hoc - Select Year and Month separately from one field?
 Login/Join
 
Silver Member
posted
Hi,

I was wondering if it was possible to split a date field (YYYY-MM-DD format) into a YEAR then a MONTH field. Then, I would allow the user to select which grouped time frame they would like to view the report. I do not want the user to select a start and end date, but instead just pick the month.
For example, a user would select FY 2013 and then select APRIL and it would show the records from 2013-04-01 to 2013-04-30.

Thanks.

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


8.0.0.2
Windows, All Outputs
 
Posts: 41 | Registered: February 27, 2014Report This Post
Gold member
posted Hide Post
One way of doing this is creating the YEAR and MONTH field in a DEFINE, with the use of the DPART function to extract the components you want:

 
 YEAR/I4 = DPART(DATE, 'YEAR', 'I11');
 MONTH/I4 = DPART(DATE, 'MM', 'I11'); 
  


Then you can update your WHERE clauses to filter on those 2 fields and create the prompts for them.


WebFOCUS App Studio 8103
Windows7
All outputs
 
Posts: 58 | Location: London, UK | Registered: May 09, 2011Report This Post
Master
posted Hide Post
Considering the performance, I would suggest to construct logic to build end date based on month selected and directly filter on the DB column instead of defined column. By this your query may use INDEX for better performance.

Thanks,
Ram
 
Posts: 542 | Location: Dearborn, MI | Registered: June 03, 2009Report 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     [CLOSED] Guided Ad Hoc - Select Year and Month separately from one field?

Copyright © 1996-2020 Information Builders