Skip to Main Content

Infrastructure Software

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Unix script error while mail the pdf file.

527335Aug 9 2006 — edited Aug 9 2006
Hi all,
I want to do a mail in pdf format via a unix script. for that i used the following query:

# Verplichte variabelen
inputname="dago130r.rdf"
outputname="$DATOUT/dago130rDC.pdf"
mailto="$MAIL_INKOOP_DC"
subject="Opgeloste PV's per Category Manager"
params="p_datum_1='08-08-2006' p_ind_dc_of_rz='D'"



# -----------------------------------
# Opgeloste PV's per Category Manager
# -----------------------------------
# Start script.
# Vanaf hier hoeft in principe niets gewijzigd te worden.

mymail () {
local tmp=$DATTMP/$$.txt
cat "$mailbody" > $tmp 2>/dev/null
do_unix "uuencode $outputname $(basename $outputname) >> $tmp"
check_success
do_unix "mailx -s '$subject' -c '$mailcc' -r '$replyto' '$mailto' < $tmp"
check_success
}


header

perform "$inputname R DESFORMAT=PDF DESTYPE=FILE DESNAME=$outputname $params"
check_success exit

mymail

footer
exit_check "$total_success"
---------------------------------------------------------------------------------------------------

When i execute this query it will make the pdf file in the output folder as well as in the tmp folder as a text file. but after that it will give me error in the log file as follows.:
---------------------------------------------------------------------------------------------------------------------
09/08/06-11:13:19 [ 25178] -- perform: Successful completion of dago130r.rdf R DESFORMAT=PDF DESTYPE=FILE DESNAME=/appl/tst/ah01/dago/dat/out/dago130rDC.pdf p_datum_1='08-08-2006' p_ind_dc_of_rz='D'
09/08/06-11:13:19 [ 25178] -- do_unix: Successful completion of uuencode /appl/tst/ah01/dago/dat/out/dago130rDC.pdf dago130rDC.pdf >> /appl/tst/ah01/dago/dat/tmp/25178.txt
[ 25178] ,/appl/tst/ah01/dago/dat/tmp/25178.txt,: No such file or directory
[ 25178] "/appl/tst/ah01/dago/home/dead.letter" 1/1
[ 25178]
09/08/06-11:13:19 [ 25178] -- ERROR do_unix: mailx -s 'Opgeloste PV's per Category Manager' -c '' -r '' 'bhavik.gor@atosorigin.com' < /appl/tst/ah01/dago/dat/tmp/25178.txt returned 1
09/08/06-11:13:19 [ 25178] --
-----------------------------------------------------------------------------------------------------------------------
I am not getting why this script not taking the file from the tmp folder and why this error comes??
please help me to go out of this problem.
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Sep 6 2006
Added on Aug 9 2006
1 comment
983 views