Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik GA: Multivariate Time Series in Qlik Predict: Get Details
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Jasper report outputs as email attachments (tJasperReportExec)

Hi , 

 

I want send jasper report outputs as email attachments

 

I am using tjasperReportExec. The job looks as shown below. If I have to send the report output as an attachment to multiple email addresses, how do I do it? As of now it stores the output in a directory. Also, if I have 10 different email and the report output differs for each email, how do I pick the relevant attachment and send it in tsendmail component? 

 

0683p000009LyLA.png

 

Also what is the difference between tjasperoutputexec, tjasperreportexec and tjasperoutput?

 

Any ideas on this will be of great help

 

Thanks

Rathi

Labels (2)
22 Replies
Anonymous
Not applicable
Author

Okay the requirement is this. I have 4 email ids, abc@xxx.com, def@xxx.com, ghi@xxx.com and jkl@xxx.com

 

And the files outputted by tjasperreportexec is report_abc.xls, report_def.xls,report_ghi.xls, report_jkl.xls

 

So, for abc@xxx.com I must pick report_abc.xls , for def@xxx.com I must pick  report_def.xls etc

fdenis
Master
Master

dose it work with a fix file
Anonymous
Not applicable
Author

Yes, it works for a fix file

fdenis
Master
Master

try with a copy of your reports and dynamic file name
Anonymous
Not applicable
Author

ahh.. I did not get you. Can you please elaborate?

fdenis
Master
Master

dynamics name as attachment:
C:/Copy_Of_Users/report_out_"+ ((Long)globalMap.get("row1.id"))+".xls"
Anonymous
Not applicable
Author

fdenis, I have used this code "C:/Users/report_out_"+ ((Long)globalMap.get("row1.id"))+".xls" and its still the same error

fdenis
Master
Master

add tlog on row1 (check name of file générated)

I'm not on your desk!
Anonymous
Not applicable
Author

fdenis, apologies for your time on a simple issue

 

I have checked  and the file name that is generated is correct and the file is present at the location mentioned

 

C:/Users/report_out_4.xls. This is the file name generated

fdenis
Master
Master

try crate report first and to iterate a second time after a onSubjodOk to send emails