The UNIX and Linux Forums  
Hello and Welcome from United States to the UNIX and Linux Forums! Thank You for Visiting and Joining Our Global Community.

Go Back   The UNIX and Linux Forums > Top Forums > Shell Programming and Scripting
.
google unix.com



Shell Programming and Scripting Post questions about KSH, CSH, SH, BASH, PERL, PHP, SED, AWK and OTHER shell scripts and shell scripting languages here.

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
uuencode for attachment giving problem manojram UNIX Desktop for Dummies Questions & Answers 3 11-19-2008 08:20 PM
question on uuencode vangalli Shell Programming and Scripting 5 07-26-2006 11:03 AM
Problem with uuencode markms Shell Programming and Scripting 0 04-07-2006 12:13 PM
Uuencode problem in mail attachment mvalonso UNIX for Dummies Questions & Answers 8 03-16-2006 01:38 PM
uuencode tejasingaraju17 Shell Programming and Scripting 2 11-20-2005 02:01 AM

Closed Thread
English Japanese Spanish French German Portuguese Italian Dutch Swedish Russian Norwegian Hungarian Hebrew Danish Powered by Powered by Google
 
LinkBack Thread Tools Search this Thread Rate Thread Display Modes
  #1 (permalink)  
Old 08-23-2007
rjsha1 rjsha1 is offline
Registered User
  
 

Join Date: Dec 2005
Posts: 33
problem with uuencode

Hi everyone,
I'm emailing a spool file to a person using mailx. I'm using uuencode to attach the file to the email. but am getting this error
uuencode: ISO8859-15 to 646 conversion: Invalid argument

Any ideas as to why. The code is below

sqlplus -s user/password@database <<EOF
set verify off
set feedback off
set pagesize 0
set linesize 60
set echo off
set wrap off
set term off
set heading off
set auto off
spool /tmp/genevabase.txt
select account_num||' '||error_message
from geneva_processing_errors;
spool off;
EOF

uuencode /tmp/genevabase.txt /tmp/genevabase.txt | mailx -s 'BASE Checks '$SYSDATE'
for ICO '$1 xxxxxx@xxxx


am I missing something glaring ???

Last edited by rjsha1; 08-23-2007 at 10:42 AM.. Reason: wrong code
  #2 (permalink)  
Old 08-23-2007
ghostdog74 ghostdog74 is offline Forum Advisor  
Registered User
  
 

Join Date: Sep 2006
Posts: 2,507
Quote:
Originally Posted by rjsha1 View Post
Hi everyone,
I'm emailing a spool file to a person using mailx. I'm using uuencode to attach the file to the email. but am getting this error
uuencode: ISO8859-15 to 646 conversion: Invalid argument

Any ideas as to why. The code is below

sqlplus -s user/password@database <<EOF
set verify off
set feedback off
set pagesize 0
set linesize 60
set echo off
set wrap off
set term off
set heading off
set auto off
spool /tmp/genevabase.txt
select account_num||' '||error_message
from geneva_processing_errors;
spool off;
EOF

uuencode /tmp/genevabase.txt /tmp/genevabase.txt | mailx -s 'BASE Checks '$SYSDATE'
for ICO '$1 xxxxxx@xxxx


am I missing something glaring ???
experiment with this : mailx -s "test" xxx@xxx and see whether it works.
  #3 (permalink)  
Old 08-23-2007
rjsha1 rjsha1 is offline
Registered User
  
 

Join Date: Dec 2005
Posts: 33
Hi mate,
tried that still the same error. It isn't something like I need to dos2unix the file or put in a ^M character.
  #4 (permalink)  
Old 08-23-2007
ghostdog74 ghostdog74 is offline Forum Advisor  
Registered User
  
 

Join Date: Sep 2006
Posts: 2,507
how about getting to the bare minimum
Code:
uuencode file file | mailx xxxx@xxx...
if that still doesn't work, then....i have no idea for you. someone else can guide you.
  #5 (permalink)  
Old 08-23-2007
rjsha1 rjsha1 is offline
Registered User
  
 

Join Date: Dec 2005
Posts: 33
Hi ghostdog,
the problem isn't the mailx bit is it the uuencode bit. Thanks for you gelp matey
  #6 (permalink)  
Old 08-18-2008
John Mac John Mac is offline
Registered User
  
 

Join Date: Feb 2005
Location: Edinburgh, Scotland
Posts: 5
A very late response, but here goes. There's a known bug in Solaris's implementation of uuencode; try typing this

unset LC_CTYPE

immediately before the uuencode command line and your error message should disappear.
  #7 (permalink)  
Old 08-18-2008
John Mac John Mac is offline
Registered User
  
 

Join Date: Feb 2005
Location: Edinburgh, Scotland
Posts: 5
Quote:
sqlplus -s user/password@database <<EOF
This isn't 100% secure because anyone who runs the command ps -ef will see your user's password. To make the password invisible, use this syntax:

Code:
echo $password | sqlplus -s user@database <<EOF

Last edited by John Mac; 08-18-2008 at 11:45 AM.. Reason: Missed the here doc code
Sponsored Links
Closed Thread

Bookmarks

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On




All times are GMT -4. The time now is 12:33 AM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited. Language Translations Powered by .
vBCredits v1.4 Copyright ©2007 - 2008, PixelFX Studios
The UNIX and Linux Forums Content Copyright ©1993-2009. All Rights Reserved.Ad Management by RedTyger

Content Relevant URLs by vBSEO 3.2.0