Focal Point
Report Caster - Passing Global Variable to Save Report As File Name

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

November 08, 2007, 01:54 PM
ColdWhiteMilk
Report Caster - Passing Global Variable to Save Report As File Name
I'm using WebFOCUS 7.1.7.

I have a global variable in my report query that holds the current date

-SET &TODAY = DATECVT &YYMD, 'I8YYMD', 'YYMD')

I would like to pass the value in &TODAY to the "Save Report As" box in Report Caster so that I can include it in the file name.

For example: FinalOutput_20071108.xls, where "20071108" comes from the &TODAY variable.

Is this possible?


Production - 7.6.4
Sandbox - 7.6.4
November 08, 2007, 02:34 PM
GinnyJakes
I'm pretty sure you can't do that. Try the IBI Advanced Search option to find more information or do a search on the Forum.

I did research on this awhile ago and I think the answer at the time was no. But someone could have put in a New Feature Request.

It is a great idea.


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
November 08, 2007, 02:52 PM
Francis Mariani
I don't know if this feasible, but if the file is not being distributed by email, you could create the file as normal and then use an OS command or an APP command to copy or rename the file to what you want.


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
November 08, 2007, 03:12 PM
Prarie
I have a report that is runs each day and saved...and then I have a fex that runs in Reportcaster that takes that and copies it with the day appended.

COPY \\velocity1\iscsc$\reports\myreport.pdf \\Corp\sahq_group\Common\myreport&MDYY...pdf


In Focus since 1993. WebFOCUS 7.7.03 Win 2003
Well, there you go then.

WarmBrownChocolate.
The problem is that the reports have to be emailed. That is where I am stuck.


Production - 7.6.4
Sandbox - 7.6.4
Yes, that would be a problem. Frowner


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
Can you e-mail them the Link?


In Focus since 1993. WebFOCUS 7.7.03 Win 2003
CWM,

If you updated your signature with the release info you gave above and your platform we might be able to advise on an alternative that would be available to that platform.

T



In FOCUS
since 1986
WebFOCUS Server 8.2.01M, thru 8.2.07 on Windows Svr 2008 R2  
WebFOCUS App Studio 8.2.06 standalone on Windows 10 
I have successfully ftp'd a dynamically created filename that contains the the current date & time portion as the filename. Granted my distribution method was ftp differs than email, but the concept would be the same.

goto http://techsupport.informationbuilders.com/sps/1096.2092.html
Ira

WF 5.3.6 AIX 533 WINDOWS XP (Development)
7.6.x (Test) Windows
5.3.x Production....


aix-533,websphere 5.1.1,apache-2.0,
wf 538(d), 537 (p),
==============
7.6.11 (t) aix 5312
websphere 6.1.19
apache 2.0
as a feeble excuse for an idea,
you could in your style sheet
,TITLETEXT='My Title &YYMD' ,
or put any form of edited &var in as titletext so that at least the TAB on the excelsheet would have the proper date on it. That works in email.

I can only get emailed .xls to title themselves whatever the fex is named. so... somehow i think you've gotta copy the fex to something temporary with todays date in the fexname,
and somehow get that scheduled.
then nuke it.
Somebody smarter will come along figure out how to do that.
I have now *completely* forgotten what i logged on to look up...happens every time.




In Focus since 1979///7706m/5 ;wintel 2008/64;OAM security; Oracle db, ///MRE/BID
I might have a solution

You can create the report with a not printed first by field and use that byfield as the burst value

The mail address you use must be in a dynamic list.

The burst value will now be put in the attachment file name.

So in coding...

DEFINE FILE CAR
DUMMYBURST=&YYMD;
END

TABLE FILE CAR
PRINT COUNTRY
BY DUMMYBURST NOPRINT
ON TABLE PCHOLD FORMAT PDF
...
END


For the DYNAMIC address list

SET ASNAMES = ON
DEFINE FILE CAR
BURST_VALUE WITH COUNTRY=&YYMD;
EMAIL_ADDRESS WITH COUNTRY='myadress@company.com';
END
TABLE FILE filename
PRINT BURST_VALUE   AS 'VALUE'
      EMAIL_ADDRESS AS 'DEST'
WHERE COUNTRY EQ 'ITALY';
ON TABLE PCHOLD
END

or use a flat file with the mail addresses....

I hope this works, could not test it at home.




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