Focal Point
[CASE-OPENED] Naming of Versions in Report Library

This topic can be found at:
https://forums.informationbuilders.com/eve/forums/a/tpc/f/7971057331/m/6837055876

September 23, 2015, 11:46 AM
wlwright1
[CASE-OPENED] Naming of Versions in Report Library
I have a number of reports that are being sent to the report library. I am using a HTML composer page where using a listbox the user can select the version of the report to run. What I am looking to do is to have instead of "Version 1" and so forth listed there that they would be a date and time the report ran so then the user can select the version of the report they want to see and run it. I've checked in the documentation and here and haven't seen anyway to do that. Does anyone have a way?

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


8.1.0.4
Windows 7
Excel, AHTML, HTML,PDF
September 23, 2015, 12:37 PM
Francis Mariani
How are you creating your listbox? I'd like to see the 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
September 23, 2015, 01:08 PM
Francis Mariani
Unfortunately, we cannot name the reports stored in Report Library. The only thing I can think of doing is providing the date/time the report version was created, but that doesn't help much.


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
September 23, 2015, 01:18 PM
wlwright1
So based on documentation I have used what I found at this link

Integrating Report Library

Even If I was able to do that I think that would be sufficient for what I'm trying to do.


8.1.0.4
Windows 7
Excel, AHTML, HTML,PDF
September 23, 2015, 01:21 PM
wlwright1
I think it may be nice to possibly submit a NFR to have this done in the advanced schedule tool. Do you agree?


8.1.0.4
Windows 7
Excel, AHTML, HTML,PDF
September 23, 2015, 02:03 PM
Francis Mariani
Absolutely - we need an NFR to be able to properly name the reports. They could have an additional column with the report name as set inside the fex, using the stylesheet syntax TYPE=REPORT, TITLETEXT=...

Meanwhile, this is a hand-coded fex that lists all the versions for a report (you will have to change the WHERE statement for your report). I have included all the columns of three tables that are involved in the Report Library entries. The fex could be modified to output the data for a dropdown list instead of a report. One issue is that the EXECUTION_TIME and EXECUTION_DATE are stored in some kind of "epoch" date/time, but the numbers themselves seem to be too high for the current epoch conversion routines, so it might be something else.

JOIN WF_NLSOBJ.OBJ_HANDLE IN wfrsmgmt/WF_NLSOBJ TO WF_REPOSOBJ.HANDLE IN wfrsmgmt/WF_REPOSOBJ AS J1
JOIN WF_REPOSOBJ.EXT_ID IN wfrsmgmt/WF_NLSOBJ TO ALL BOTLIB.REPORTGID IN wfrsmgmt/BOTLIB AS J2
-RUN

-SET &GMT_OFFSET_HOURS = -4;

TABLE FILE wfrsmgmt/WF_NLSOBJ
PRINT
SEG.WF_NLSOBJ.OBJ_HANDLE
SEG.WF_REPOSOBJ.HANDLE
SEG.BOTLIB.REPORTGID

COMPUTE ICASTERBASE/I8YYMD = 19700101; NOPRINT
COMPUTE CASTERBASE/YYMD = ICASTERBASE; NOPRINT

COMPUTE EXECUTION_TIME_X/A13 =  SUBSTR(32, EXECUTION_TIME, 20, 32, 13, EXECUTION_TIME_X); NOPRINT
COMPUTE EXECUTION_TIME_NUM/D13 =  EDIT(EXECUTION_TIME_X); NOPRINT

COMPUTE CASTERBASEDTM/HYYMDS = DT(19700101 00:00:00Z); NOPRINT

COMPUTE EXECUTION_DTTM_TEMP/HYYMDS = HADD(CASTERBASEDTM, 'MILLISECONDS', EXECUTION_TIME_NUM, 8, 'HYYMDS'); NOPRINT
COMPUTE EXECUTION_DTTM/HYYMDS = HADD(EXECUTION_DTTM_TEMP, 'HOUR', &GMT_OFFSET_HOURS, 8, 'HYYMDS');

BY OBJDESC NOPRINT
BY VERSION NOPRINT
WHERE
WF_NLSOBJ.PRT_PATH LIKE '%Library_Content/Cash%'
END
-RUN

-*http://dviappvmwebf03/ibi_apps/lib-report.rc?&id=7f219632I6c69I45e2Ia1bdI64c9ff3630f3&BIDrand=687
-*http://dviappvmwebf03/ibi_apps/lib-report.rc?&id=7f219632I6c69I45e2Ia1bdI64c9ff3630f3&version=50&IBIWF_SES_AUTH_TOKEN=498dde196f305d5483ab162affd37efb
* Updated to include code to convert EXECUTION_TIME to human-readable date/time, as per Susannah's tip, Zulu Time – How to Read the ReportCaster Schedule File. I don't have a clue if Daylight Savings Time is applied...

Note that you will have to generate metadata for these Repository and Report Caster tables.

This message has been edited. Last edited by: Francis Mariani,


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
September 28, 2015, 02:22 PM
wlwright1
thanks I'm going to try this. When you do this, do you include in each fex or do you have this be it's own fex and then do an include in each fex so you can pull in the paramaters.

I'm just trying to determine how this would work in how I have this formatted within the HTML page in the listbox. It could be when they click on the Version it shows a table below with this information and then run the report.


8.1.0.4
Windows 7
Excel, AHTML, HTML,PDF