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] Dates in Page Header

Read-Only Read-Only Topic
Go
Search
Notify
Tools
[SOLVED] Dates in Page Header
 Login/Join
 
Platinum Member
posted
I have two dates as DEFINE in my master file

DEFINE Day1/HMDYYS=HGETC(8,'HYYMDS');,
TITLE='Current Day', $
DEFINE Yesterday/HMDYYS=DTADD(Day1,DAY,-1);,
TITLE='Yesterday', $

I use these in my fex to run audit reports for the last 24 hours. The fex runs fine and pulls the right information. I have in the page header of the reports these defined masterfile fields, as below (just posting a snippet of the code)

HEADING
"Eastern CT State University"
"Daily Direct DB Report for All Users"
"From WHERE ( DBA_AUDIT_TRAIL.DBA_AUDIT_TRAIL......

When the fex is scheduled the page header dates come up as blanks when there are no results from the pull. When there are results the date fields are visible.

I tried creating the date fields in the .fex and using that but these do not appear either. How do you get the date fields to appear in the header even if there are no results. These reports are for auditing purposes and need to have the date fields in them.

Thanks

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


WF8
Windows
 
Posts: 117 | Registered: May 28, 2015Report This Post
Platinum Member
posted Hide Post
I just looked at the post and noticed that the line with the date fields was missing so am reposting that code now. Don't know how that happened because I didn't edit it out, hmmmm... So am trying to repost that code again.

HEADING
"Eastern CT State University"
"Daily Direct DB Report for All Users"
"From WHERE ( DBA_AUDIT_TRAIL.DBA_AUDIT_TRAIL.DBTIMESTAMP GE Yesterday ) AND .....


WF8
Windows
 
Posts: 117 | Registered: May 28, 2015Report This Post
Platinum Member
posted Hide Post
And again the code didn't copy, what is up with that? The code looks like this when I open it in text editor. When I copy and paste it into focal point I loose a portion of the 4th line.

HEADING
"Eastern CT State University"
"Daily Direct DB Report for All Users"
"From WHERE (DBA_AUDIT_TRAIL.DBA_AUDIT_TRAIL.DBTIMESTAMP ......

Anything after the WHERE is irrelevant.


WF8
Windows
 
Posts: 117 | Registered: May 28, 2015Report This Post
Expert
posted Hide Post
Trudy, when you post code, please use the </> button (at the top-right of the post window) to generate code tags, then paste the code between these tags. Sometimes code will not display properly because it can be interpreted as HTML.

[code]
you code here
[/code]


Francis


Give me code, or give me retirement. In FOCUS since 1991

Production: WF 7.7.05M, Dev Studio, BID, MRE, WebSphere, DB2 / Test: WF 8.1.05M, App Studio, BI Portal, Report Caster, jQuery, HighCharts, Apache Tomcat, MS SQL Server
 
Posts: 10577 | Location: Toronto, Ontario, Canada | Registered: April 27, 2005Report This Post
Platinum Member
posted Hide Post
OK, sorry everyone for being such a newbie but this last time I typed in the code and it removed the characters.


This is found after the From on line 4
The WHERE starts on line 5


WF8
Windows
 
Posts: 117 | Registered: May 28, 2015Report This Post
Platinum Member
posted Hide Post
All right, feel like a fool now. Here is the code.

 
HEADING
"Eastern CT State University"
"Daily Direct DB Report for All Users"
"From <Yesterday to  <Day1 "
WHERE ( DBA_AUDIT_TRAIL.DBA_
 


Thanks Francis, won't make that mistake again.


WF8
Windows
 
Posts: 117 | Registered: May 28, 2015Report This Post
Virtuoso
posted Hide Post
Do you need the timestamp? If you don't need it, the standard & Date fields in the heading even when the report is empty seems to work. If you need the actual time, then you'll have to also place &TOD in the heading instead of using the Defined fields.

TABLE FILE CAR
BY COUNTRY
BY CAR
ON TABLE SUBHEAD
" &DATETMDYY &TOD"
WHERE COUNTRY EQ 'RUSSIA';
ON TABLE SET EMPTYREPORT ON
END


WebFOCUS 8206, Unix, Windows
 
Posts: 1853 | Location: New York City | Registered: December 30, 2015Report This Post
Expert
posted Hide Post
quote:
when there are no results from the pull

Is this an empty report? The problem is that you're using DEFINE fields, which are report columns - if there are no report rows, the dates will not display.

Play with the EMPTYREPORT setting. Try SET EMPTYREPORT=ANSI.

quote:

The syntax is:

SET EMPTYREPORT={ANSI|ON|OFF}

where:

ANSI - Produces a single-line report and displays the missing data character or a zero if a COUNT is requested. In each case, &RECORDS will be 0, and &LINES will be 1.

If the SQL Translator is invoked, ANSI automatically replaces OFF as the default setting for EMPTYREPORT.

ON - Produces an empty report (column headings with no content). This was the default behavior in prior releases.

OFF - Produces no report output. OFF is the default value except for SQL Translator requests. When the SQL Translator is invoked, ANSI replaces OFF as the default setting for the EMPTYREPORT parameter, so the results are the same as for the ANSI setting.

The command can also be issued from within a request using:

ON TABLE SET EMPTYREPORT ON


Francis


Give me code, or give me retirement. In FOCUS since 1991

Production: WF 7.7.05M, Dev Studio, BID, MRE, WebSphere, DB2 / Test: WF 8.1.05M, App Studio, BI Portal, Report Caster, jQuery, HighCharts, Apache Tomcat, MS SQL Server
 
Posts: 10577 | Location: Toronto, Ontario, Canada | Registered: April 27, 2005Report This Post
Platinum Member
posted Hide Post
Thanks all, I did try the SET EMPTYREPORT settings with no luck. The &DATETMDYY &TOD does work, but I want to do it for a date range, from yesterday to today. So I believe the easiest way for me to do this is to use DM and create an &variable for yesterday and use this along with the &DATEMDYY &TOD in my header. My last question for you all is where do I find documentation on the various 'functions' that are available for use in DM?

Thanks again


WF8
Windows
 
Posts: 117 | Registered: May 28, 2015Report This Post
Virtuoso
posted Hide Post
-SET &YESTERDAY=AYMD(&YYMD,-1,'I8YYMD');


WebFOCUS 8206, Unix, Windows
 
Posts: 1853 | Location: New York City | Registered: December 30, 2015Report 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] Dates in Page Header

Copyright © 1996-2020 Information Builders