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] Request for new HOLD format EMAIL

Read-Only Read-Only Topic
Go
Search
Notify
Tools
[CLOSED] Request for new HOLD format EMAIL
 Login/Join
 
Member
posted
A couple ideas for new HOLD formats came up during one of the many 'hallway' meetings that always occur at Summit this year. The EMAIL idea is for something like this:

TABLE FILE DATA
PRINT SOMETHING
ON TABLE HOLD FORMAT EMAIL someone@somewhere
END

This doesn't offer a way to include the subject line or body information unless it could accept standard form 'mailto' syntax:

ON TABLE HOLD FORMAT EMAIL 'mailto:someone@somewhere?subject=Your Report&body=Short Message'

Of course the ampersand before the 'body' argument is problematic to Focus. Maybe the standard url encoding form would be required: %26 .

Or maybe with special heading types/attributes, i.e.:

TABLE FILE DATA
HEADING MAILTO
"someone@somewhere"
HEADING SUBJECT
"Your Latest Report"
HEADING BODY
"Multi Line Info"
"text text text"
PRINT SOMETHING
ON TABLE HOLD FORMAT EMAIL someone@somewhere
END

In case anybody is thinking of pointing out that Report Caster is designed to do this very thing, I'd like to point out that it actually does a different kind of job that this idea doesn't address. Report Caster runs autonomously to distribute data to a known recipient base on a regular schedule. The idea presented in this post wouldn't replace that. This idea would likely be used, in example, where a customer enters data on a web page to update a form which triggers an acknowledgment email. I don't believe Report Caster is able to provide that unless coded at the API level and even then I think it's overkill.

On another day, and if this topic gets much attention, I'll post the code we use here at UNT Health Science Center. We use WebFocus to prepare the email payload and then either copy a POP3 format file into a Microsoft IIS SMTP Server PICKUP directory, or use Perl NET::SMTP as an SMTP Client to deliver the email message to our email gateway.

This message has been edited. Last edited by: Kerry,
 
Posts: 14 | Location: Texas | Registered: May 16, 2006Report This Post
Expert
posted Hide Post
Steve, good idea, to have a chance of this to happen, you will have to put in an NFR (New Feature Request) with IBI.

Currently when we want to email, we have to create the mail under program control and call the OS to send it.


Waz...

Prod:WebFOCUS 7.6.10/8.1.04Upgrade:WebFOCUS 8.2.07OS:LinuxOutputs:HTML, PDF, Excel, PPT
In Focus since 1984
Pity the lost knowledge of an old programmer!

 
Posts: 6347 | Location: 33°49'23.0"S, 151°11'41.0"E | Registered: October 31, 2006Report This Post
Member
posted Hide Post
I want to make sure many people get to review the idea before a NFR is created. That way it stands a better chance of being useful and is clear to IBI development staff how and what to implement. And, more important, if this isn't something that many customers would actually use, then the way we are doing it now, and sharing how we do that, will save lots of development time that IBI can use for better things.
 
Posts: 14 | Location: Texas | Registered: May 16, 2006Report This Post
Expert
posted Hide Post
Good point.

For IBI to even consider making the change, they need to know its worth it, so the more people that put in the NFR the better.


Waz...

Prod:WebFOCUS 7.6.10/8.1.04Upgrade:WebFOCUS 8.2.07OS:LinuxOutputs:HTML, PDF, Excel, PPT
In Focus since 1984
Pity the lost knowledge of an old programmer!

 
Posts: 6347 | Location: 33°49'23.0"S, 151°11'41.0"E | Registered: October 31, 2006Report This Post
Expert
posted Hide Post
As there is already the TITLE syntax within style sheets, my vote would be for that to be utilised as the subject line. That might have a little more success in an NFR that expanding the HEADING keyword to allow additional suffixes. I always get wary when syntax is extended to such degrees that it takes a few releases to iron out the "features".

On the whole though, a great idea.

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 
 
Posts: 5694 | Location: United Kingdom | Registered: April 08, 2004Report This Post
Master
posted Hide Post
How about using the stylesheet to add the correct subject and/or body?

( like naming the worksheets in excel )

?


_____________________
WF: 8.0.0.9 > going 8.2.0.5
 
Posts: 668 | Location: Veghel, The Netherlands | Registered: February 16, 2010Report This Post
Virtuoso
posted Hide Post
Interesting and it would be very useful. The one problem I see is that this would REQUIRE mail services/server to be available on the same platform as the WebFOCUS server, which could be a restriction on several platforms. I don't really see an easy way around that one. I'm sure there's a more complicated one.


Regards,

Darin



In FOCUS since 1991
WF Server: 7.7.04 on Linux and Z/OS, ReportCaster, Self-Service, MRE, Java, Flex
Data: DB2/UDB, Adabas, SQL Server Output: HTML,PDF,EXL2K/07, PS, AHTML, Flex
WF Client: 77 on Linux w/Tomcat
 
Posts: 2298 | Location: Salt Lake City, Utah | Registered: February 02, 2007Report This Post
Expert
posted Hide Post
Have you seen the EDAMAIL option in 7.7 ?


Waz...

Prod:WebFOCUS 7.6.10/8.1.04Upgrade:WebFOCUS 8.2.07OS:LinuxOutputs:HTML, PDF, Excel, PPT
In Focus since 1984
Pity the lost knowledge of an old programmer!

 
Posts: 6347 | Location: 33°49'23.0"S, 151°11'41.0"E | Registered: October 31, 2006Report This Post
Expert
posted Hide Post
no, Waz.... what is the edamail option?




In Focus since 1979///7706m/5 ;wintel 2008/64;OAM security; Oracle db, ///MRE/BID
 
Posts: 3811 | Location: Manhattan | Registered: October 28, 2003Report This Post
Expert
posted Hide Post
Pretty Cool. From the New Features Doc:

  
Sending E-mail From a Procedure With File Content or an Attachment
E-mails can be sent from a procedure with the content of a specific file included in the body
of the email or as an attachment.
The syntax is:
EX EDAMAIL to, from, subject, [flag], filetype, data
where:
to
Is the e-mail recipient.
from
Is the e-mail sender.
subject
Is the e-mail subject.
flag
If flag is set to "a", the file is sent as an attachment. Otherwise, it is included in the
body of the e-mail.
filetype
Defines the data type, such as MASTER, FOCEXEC, HTML, and so on.
data
Is the data or [app/]filename with the mail content.


Tom Flynn
WebFOCUS 8.1.05 - PROD/QA
DB2 - AS400 - Mainframe
 
Posts: 1972 | Location: Centennial, CO | Registered: January 31, 2006Report This Post
Expert
posted Hide Post
oh man! that rocks.




In Focus since 1979///7706m/5 ;wintel 2008/64;OAM security; Oracle db, ///MRE/BID
 
Posts: 3811 | Location: Manhattan | Registered: October 28, 2003Report This Post
Virtuoso
posted Hide Post
So I'm guessing that all of those can be replace with &vars and parameterize the whole line. Takes ReportCaster out of the picture for the easy stuff. -- Keeping my fingers crossed for that one.


Regards,

Darin



In FOCUS since 1991
WF Server: 7.7.04 on Linux and Z/OS, ReportCaster, Self-Service, MRE, Java, Flex
Data: DB2/UDB, Adabas, SQL Server Output: HTML,PDF,EXL2K/07, PS, AHTML, Flex
WF Client: 77 on Linux w/Tomcat
 
Posts: 2298 | Location: Salt Lake City, Utah | Registered: February 02, 2007Report This Post
Expert
posted Hide Post
The real problem with the new features, is upgrading, we have been trying to two years.


Waz...

Prod:WebFOCUS 7.6.10/8.1.04Upgrade:WebFOCUS 8.2.07OS:LinuxOutputs:HTML, PDF, Excel, PPT
In Focus since 1984
Pity the lost knowledge of an old programmer!

 
Posts: 6347 | Location: 33°49'23.0"S, 151°11'41.0"E | Registered: October 31, 2006Report This Post
Virtuoso
posted Hide Post
Same here. It took about 3 years to finall get to 7.6.x from 7.1 and now 7.7 is there (with 8 on the horizon.) Just have to wait until there are enough of those must-haves to justify the migration to a new version.


Regards,

Darin



In FOCUS since 1991
WF Server: 7.7.04 on Linux and Z/OS, ReportCaster, Self-Service, MRE, Java, Flex
Data: DB2/UDB, Adabas, SQL Server Output: HTML,PDF,EXL2K/07, PS, AHTML, Flex
WF Client: 77 on Linux w/Tomcat
 
Posts: 2298 | Location: Salt Lake City, Utah | Registered: February 02, 2007Report This Post
Expert
posted Hide Post
Ditto...

7.7 may have some nice things, but what will 8 have ?

To Upgrade or to wait, that is the question.


Waz...

Prod:WebFOCUS 7.6.10/8.1.04Upgrade:WebFOCUS 8.2.07OS:LinuxOutputs:HTML, PDF, Excel, PPT
In Focus since 1984
Pity the lost knowledge of an old programmer!

 
Posts: 6347 | Location: 33°49'23.0"S, 151°11'41.0"E | Registered: October 31, 2006Report This Post
Virtuoso
posted Hide Post
Oh boy! And to think that we're still running on 5.3.4 Roll Eyes



Prod/Dev: WF Server 8008/Win 2008 - WF Client 8008/Win 2008 - Dev. Studio: 8008/Windows 7 - DBMS: Oracle 11g Rel 2
Test: Dev. Studio 8008 /Windows 7 (Local) Output:HTML, EXL2K.
 
Posts: 1533 | Registered: August 12, 2005Report This Post
Expert
posted Hide Post
OMG.....


Waz...

Prod:WebFOCUS 7.6.10/8.1.04Upgrade:WebFOCUS 8.2.07OS:LinuxOutputs:HTML, PDF, Excel, PPT
In Focus since 1984
Pity the lost knowledge of an old programmer!

 
Posts: 6347 | Location: 33°49'23.0"S, 151°11'41.0"E | Registered: October 31, 2006Report This Post
Expert
posted Hide Post
quote:
we're still running on 5.3.4
Alright, you don't have to make me jealous Wink New features are nice to have but sometimes the impact on performance and other "features" outweigh the advantages.

As for the EDAMAIL, nice extension of the product but I suppose that I'll have to wait a while. However, I have been using a similar method that I wrote using VB Script, primarily for Excel files that need compaction first but it would work for any file.

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 
 
Posts: 5694 | Location: United Kingdom | Registered: April 08, 2004Report This Post
Gold member
posted Hide Post
quote:
Originally posted by Waz:
Ditto...

7.7 may have some nice things, but what will 8 have ?

To Upgrade or to wait, that is the question.


I think 7.7 will have a smoother upgrade path to 8.


------------------------------------------
DevStudio 8.2.03
WFS 8.2.03
 
Posts: 86 | Location: Atlanta | Registered: May 10, 2007Report This Post
Gold member
posted Hide Post
Prior to 7.7 this is the solution I came up with. Seems like IBI has implemented about the same idea. Sendemail is a command line SMTP email client which supports Linux, BSD, OS X, Windows 98, Windows NT, Windows 2000, & Windows XP. SendEmail will allow you to attach files which you can attach reports or you can just send a link to a fex and the recipient can run the report.

-* File sendemail.fex
-SET &ECHO=ALL;

-* You can use these in your code if you have user setup
-* MR remote user - &IBIMR_user
-* WF remote user - &WF_REMOTE_USER

-DEFAULTS &FROMADDRESS = 'Webfocus <from@whatever.com>';
-DEFAULTS &TOADDRESS = 'Administrator <to@whatever.com>';
-DEFAULTS &REPLYADDRESS = 'Webfocus <reply@whatever.com>';
-DEFAULTS &CCADDRESS = '';
-DEFAULTS &BODY = 'Email Body Blank';
-DEFAULTS &SUBJECT = 'Email Subject Blank';
-DEFAULTS &MAILSERVER = 'server.whatever.com';
-DEFAULTS &REPORTFEX = 'PROD_BATCH_INQUIRY';
-DEFAULTS &PARM1 = 'PDBCH=';
-DEFAULTS &PARM1VAL = 'A558B09';

-SET &TOADDRESS = 'To <to@whatever.com>';
-SET &CCADDRESS = 'CC <CC@whatever.com>';
-SET &SUBJECT = 'Batch Information Review';
-SET &REPORTPARMS = IF &PARM1 NE '' THEN '&' || '&PARM1.EVAL' || '&PARM1VAL.EVAL' ELSE '';

-SET &BODY = '<html><body>The following batch needs your review.<p>' ||
-'<a href=http://wfserver:8080/ibi_apps/WFServlet?' ||
-'IBIF_webapp=/ibi_apps&' ||
-'IBIC_server=EDASERVE&' ||
-'IBIWF_msgviewer=OFF&' ||
-'IBIAPP_app=tiadev_tr&' ||
-'IBIF_ex=' || &REPORTFEX || &REPORTPARMS ||
-'>&PARM1VAL.EVAL</a></body></html>';

-SET &QT='"' ;
-SET &MAILFILE = 'F:\ibi\apps\tiadata\sendEmail.exe';
-SET &MAILCMD = '&MAILFILE.EVAL' |
-   ' -f ' | &QT || &FROMADDRESS || &QT |
-   ' -t ' | &QT || &TOADDRESS || &QT |
-   ' -u ' | &QT || &SUBJECT || &QT |
-   ' -m ' | &QT || '&BODY' || &QT |
-   ' -s ' | &MAILSERVER |
-   ' -cc ' | &QT || &CCADDRESS || &QT |
-   ' -o reply-to=' | &QT || &REPLYADDRESS || &QT;

-WINNT &MAILCMD.EVAL
-*-TYPE &MAILCMD.EVAL
-EXIT


Code above builds the following:
 F:\ibi\apps\tiadata\sendEmail.exe -f "Webfocus <from@whatever.com>" -t "To <to@whatever.com>" -u "Batch Information Review" -m "<html><body>The
following batch needs your review.<p><a href=http://wfserver:8080/ibi_apps/WFServlet?IBIF_webapp=/ibi_apps&IBIC_server=EDASERVE&IBIWF_msgviewer=OFF
&IBIAPP_app=tiadev_tr&IBIF_ex=PROD_BATCH_INQUIRY&PDBCH=A558B09>A558B09</a></body></html>" -s server.whatever.com -cc "CC <CC@whatever.com>"
 -o reply-to="Webfocus <reply@whatever.com>"
 

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


------------------------------------------
DevStudio 8.2.03
WFS 8.2.03
 
Posts: 86 | Location: Atlanta | Registered: May 10, 2007Report This Post
Virtuoso
posted Hide Post
quote:
EDAMAIL



Edamail os already working in 7.6.x

We use it for example to update users automatical in case of reporting requests.

EX -lines 18 EDAMAIL &MAIL.EVAL; IBI@kempen.nl,
  ,
 IBI informationrequest &INFOSUBJECT.EVAL,
  ,
  ,
bla bla bla blaa:
&INFONAAM.EVAL
-------------------------------------------------------------------------
Reuest will be executed by: &MEDEWERKER.EVAL.
OldStatus: &OUDSTATUS.EVAL.
NewStatus: &NIEUWSTATUS.EVAL.
-------------------------------------------------------------------------
Remarks: &MAIL2INHOUD
-------------------------------------------------------------------------
&MAILDISCLAIMER
-------------------------------------------------------------------------
Greetings,
department IBI
ibi@kempen.nl
-*


As you can see some amper values in this message which will be filled by the preceding report.
The amper value &MAIL is the adress of the receveiver.

BTW we have found this in the documentation of ETL (Datamigrator) so I am not sure it can be used for everybody.
Not sure if an attachement can be sent within this option.




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
Member
posted Hide Post
I just tried EDAMAIL on 7.6.11 and it basically works. Thanks to FrankDutch for the example. I wasn't able to make sense of the other command line options, i.e., FOCEXEC or MASTER. I wasn't able to reference an external file of any kind to be sent as the body or as an attachment. I haven't found any explanation on how to use EDAMAIL in the manuals. In all cases, leaving the filetype blank caused the last argument to become the body of the email. All other variations I tried resulted in an email with an empty body and no attachment. It's a start and looks like this is a solution to my first post. It's more flexible than my idea, and in the form that works, allows me to generate an email for a variety of different reporting conditions.

I did need to set up SMTP_HOST on the WebFocus Server, Web Console, Workspace Configuration, General, E-Mail setting to point to my SMTP gateway. As Darin mentioned, there needs to be an SMTP server, but not necessarily on the same box. In every instance of being able to email from a Focus procedure, or any other language procedure, PHP, Perl, C, etc., there needs to be a SMTP server available. This can be your organizations SMTP gateway, your ISP's outgoing mail server, or a localhost SMTP server. You should be careful setting up a localhost that you don't become a spam relay. It's much better to use an already available SMTP gateway (in this text, I use the word gateway to mean an SMTP server that recognizes my WebFocus server's IP address as authorized to relay mail, or one that I have a login username and password for. An SMTP server is just the application that knows how to look up MX records and connect to other SMTP servers to relay mail.).

This message has been edited. Last edited by: Steve F,
 
Posts: 14 | Location: Texas | Registered: May 16, 2006Report This Post
Virtuoso
posted Hide Post
Steve

you can send an attachement, but I never tried that.
look at the first line in the code....it says "lines 18" and that is a variable number.
the number of lines followed need to match that number
I did not find any documentation so far, but it works




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
  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] Request for new HOLD format EMAIL

Copyright © 1996-2020 Information Builders