How to send PDFs?

Andrew2009

Well Known Member
Once a RD job is finished and the BI publishing process is done. We want to send the resulting PDF to a 3rd party system. Do you know how to do that? We want to automate the process in JDE as much as possible.

If you have other simple approaches, can you let me know please?

Thanks

JDE 9.1
 
Depending on your tools release, you may also be able to specify a file system location for the resulting PDF to be placed into. This is done using app P95641. I think this might be in tools 9.1.4.x and higher.
 
Andrew2009,

I have accomplished this task a few months ago.
The functionality is achieved using two UBEs
1. Driver UBE
2. Output UBE

The Driver UBE calls the Output UBE and gets the Server Job Number. To do so, we need to use Launch Batch Application business function.

Once we have the Server Job Number, we can populate the complete path to the Output UBE pdf using series of 'concat' functions. For example, the pdf stored as ...\PrintQueue\R59XXX_VERXXX_ServerJobNumber.pdf.

Then we can use Email Merge Letter to send this file to specified email address.
 
I do similar to Rauf,

I have a driver UBE, from this I launch a output UBE and get job number. Next, I compose part of BIP number name(depend of release) UBE_VERSION_JOBN_* and with a command (depend ssoo) as file output (e.g. linux: '/bin/ls -1 ',concat(directory,concat(' | egrep -i $*.csv > ', concat(directory,concat('/','tempFile.tmp')) ) I find in BI Publisher directory, get reading the complete BIP name and then send email or any action.

The BIP problem is the name contain a internal next number and not it's possible recover from any table.

Regards.
 
If you try my method, there is no driver UBE needed. So any UBE can be added to the process by simple config of a custom table in minutes.

So it's develop once and forget type thing. Providing people read your manual and setup the remaining config :)
 
John - Your method uses OSA interface, right? If so, it cannot be used to handle BI publisher output (which is what Andrew2009 wants) because the the BI publisher jobs is submitted asynchronously. So, the code in the OSA interface will (or may) complete before the BI publisher job completes. You will need more code to monitor the BI publisher jobs. Also, BI publisher output is not stored as file (unless you archive it), so those code changes will need to be incorporated as well.
 
alfredorz,

Depending on your tools release, you can specify a name for attachments, so they can have a meaningful name like WO_450102.pdf, so you don't have to rely on the cryptic default naming convention from Oracle.
 
Another option is to auto email the BIP with its metadata encoded in the subject line of the email. I have used this method with an email enabled SharePoint library. Once the document is in the library you can create calculated columns which parse the subject into meaning fields. The downside of this approach is the number of moving parts involved.

Don's approach of embedding the metadata into the file name is probably a more robust approach available in the newer Tools Releases, particularity for systems which do not have a native email handler.
 
John - Your method uses OSA interface, right?

No, that was what I initially tried/explored.

My method simply uses a scheduled UBE sweeping over F986110 with an incrementing and saved job # looking for completed jobs that match values in a config file. Or Jobs that have taken an age to complete, if needed.

Instead of trying to get all this output stuff when the job is running, just wait and get it when the job is done. Far easier.

The config file controls the type of action you may want to do with the UBEs output.
Be that CSV, PDF or XML

You set the flag and point the 'get attachment' type emailing BSFNs to get the CSV PDF or XML BI output file.

I'll be honest I haven't added the BI side of it, but that won't be too hard as I did look at it. It just wasn't needed as they email themselves anyway.
Just find the BIP repository address on your server and plug it in to the code. Add a new tick box on my config screen for BI output, job done.

You can even change the name of the attachment once you have the file. But you need to knows its original name in order to get it.
 
Back
Top