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] Date format along the X Axis

Read-Only Read-Only Topic
Go
Search
Notify
Tools
[SOLVED] Date format along the X Axis
 Login/Join
 
Silver Member
posted
Hi,

I need the date value along the X axis to be displayes as Mondd, when Mon is the 3 digit month and dd is the date from 01 to 30/31.
Please let me know how I can accomplish this
Thanks

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


769
Windows

Using all the above
 
Posts: 34 | Registered: August 08, 2009Report This Post
Virtuoso
posted Hide Post
you can define a new field based on the datefield.

something like this

DEFINE FILE OPT_M_HI
MAAND/Mt=PRE_WRKDAG;
END
GRAPH FILE OPT_M_HI
SUM CNT.SOM_BRUTO 
ACROSS MAAND 
ON GRAPH SET LOOKGRAPH VBAR
ON GRAPH SET GRAPHEDIT SERVER
...




Frank

prod: WF 7.6.10 platform Windows,
databases: msSQL2000, msSQL2005, RMS, Oracle, Sybase,IE7
test: WF 7.6.10 on the same platform and databases,IE7

 
Posts: 2387 | Location: Amsterdam, the Netherlands | Registered: December 03, 2006Report This Post
Silver Member
posted Hide Post
This will display only the 3 character month. I also need the day of the month to be appended to this month.


SQL SQLORA

SELECT
START_WEEK,
'PHASE'||PHASE AS PHASE,
COUNT(DISTINCT IBD_NUM) AS IBD_NUM
FROM PROD_LOGINS_WEEKLY_TEMP
WHERE USER_CATEGORY IN('Pure 360','Mixed 360') AND PHASE<>0 AND GROUP_FLD IN('DBS','GSS','NC')
AND START_WEEK BETWEEN (TRUNC(SYSDATE,'DAY')+1)-70 AND ((TRUNC(SYSDATE,'DAY')+1)-7)+ 6
GROUP BY START_WEEK,
PHASE
ORDER BY PHASE;

SQL SQLORA END SESSION;

TABLE FILE SQLOUT
PRINT
*
AND
COMPUTE TRANSDATE/YYMD = HDATE(START_WEEK, 'YYMD');
TIMELINE/MDY=TRANSDATE;
AND COMPUTE START_WEEK1/Mt=TRANSDATE;
START_WEEK_D/D=TRANSDATE;
-*********** I am not able to concatenate month and date as I tried to do in the below line which throws error ****----
COMPUTE MONTH_DAY = START_WEEK1||START_WEEK_D;
ON TABLE HOLD AS H1
END


TABLE FILE H1
PRINT *
END

Thanks


769
Windows

Using all the above
 
Posts: 34 | Registered: August 08, 2009Report This Post
Virtuoso
posted Hide Post
This might work:

TRANSDATE2/A11 = DATETRAN(TRANSDATE,'(YYMD)','(t)','EN',11,'A11');
TRANSDATE3/A5  = EDIT(TRANSDATE2,'$$$$$999$99');


WebFOCUS 7.7.05
 
Posts: 1213 | Location: Seattle, Washington - USA | Registered: October 22, 2007Report This Post
Silver Member
posted Hide Post
Hi,

Thanks for the response. I was able to reproduce the same using the below command:

COMPUTE TIMELINE/A7=EDIT(CHGDAT('YMD', 'MTYY', EDIT(TIMELINE1), 'A17'),'9999,$$99');
COMPUTE TIMELINE_D/A7=EDIT(CHGDAT('YMD', 'MTD', EDIT(TIMELINE1), 'A17'),'9999,99');

But in both the cases, we are converting it to alpha numeric format. Hence while displaying the date in the X axis in graph, it gets sorted alphabetically. Hence Feb comes before Jan.
Please let me know if there is any option to convert this to date again so as to display as date along graph's X Axis.

Thanks


769
Windows

Using all the above
 
Posts: 34 | Registered: August 08, 2009Report This Post
Virtuoso
posted Hide Post
Can you sort by TIMELINE1 first with NOPRINT?

GRAPH FILE <filename>
SUM ....
BY TIMELINE1 NOPRINT
BY TIMELINE
.
.
.
END


WebFOCUS 7.7.05
 
Posts: 1213 | Location: Seattle, Washington - USA | Registered: October 22, 2007Report This Post
Virtuoso
posted Hide Post
Two byfields will not work in a graph

Is it acceptable if the year is visible ?

if that is no problem you can say

MAAND/YMtD =PRE_WRKDAG;


try to use smartdates....

did you take a look in the manual for graphics?

how many days do you expect in your graph?
if it is more then 20, it will be difficult to read the days.




Frank

prod: WF 7.6.10 platform Windows,
databases: msSQL2000, msSQL2005, RMS, Oracle, Sybase,IE7
test: WF 7.6.10 on the same platform and databases,IE7

 
Posts: 2387 | Location: Amsterdam, the Netherlands | Registered: December 03, 2006Report This Post
Silver Member
posted Hide Post
Hi,

The user needs the data only in that format.
Even if use BY field with NOPRINT, the BY field is also appearing the legend which is not desirable..


769
Windows

Using all the above
 
Posts: 34 | Registered: August 08, 2009Report This Post
Virtuoso
posted Hide Post
You might try this. Since START_WEEK already appears to be in a date-time format of HYYMDS, simply convert it to a date-time format of HMtD ("Mon DD"). Hopefully, this date-time field will sort properly in the graph.

TIMELINE/HMtD = START_WEEK ;


WebFOCUS 7.7.05
 
Posts: 1213 | Location: Seattle, Washington - USA | Registered: October 22, 2007Report This Post
Silver Member
posted Hide Post
Yes, this works fine, Thanks..


769
Windows

Using all the above
 
Posts: 34 | Registered: August 08, 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     [SOLVED] Date format along the X Axis

Copyright © 1996-2020 Information Builders