HPE GreenLake Administration
- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Re: ksh variable problem
Operating System - HP-UX
1833800
Members
2557
Online
110063
Solutions
Forums
Categories
Company
Local Language
back
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
back
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Blogs
Information
Community
Resources
Community Language
Language
Forums
Blogs
Go to solution
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-22-2004 02:18 AM
01-22-2004 02:18 AM
I have a ksh script that mailx a file.
The problem I am having is that the variable that I put for the subject only out put the first word.
MAIL=/bin/mailx
MAILTO=lhradowy@whatever.ca
SUBJECT="Database Archive Logs"
Here is my mail...
$MAIL -s $SUBJECT $MAILTO < $BACKUP_TEMP_LOG
When I get my mail, the subject only says...
Database
The problem I am having is that the variable that I put for the subject only out put the first word.
MAIL=/bin/mailx
MAILTO=lhradowy@whatever.ca
SUBJECT="Database Archive Logs"
Here is my mail...
$MAIL -s $SUBJECT $MAILTO < $BACKUP_TEMP_LOG
When I get my mail, the subject only says...
Database
Solved! Go to Solution.
3 REPLIES 3
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-22-2004 02:23 AM
01-22-2004 02:23 AM
Re: ksh variable problem
First, have you tried single quotes?
Second, here's an overly simplistic suggestion:
SUBJECT="DatabaseArchiveLogs"
-or-
SUBJECT="Database_Archive_Logs"
Pete
Pete
Second, here's an overly simplistic suggestion:
SUBJECT="DatabaseArchiveLogs"
-or-
SUBJECT="Database_Archive_Logs"
Pete
Pete
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-22-2004 02:23 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-22-2004 02:25 AM
01-22-2004 02:25 AM
Re: ksh variable problem
Try-
$MAIL -s "$SUBJECT" $MAILTO <$BACKUP_TEMP_LOG
Putting double quotes around subject tells the shell to treat it as one parameter.
HTH
-- Rod Hills
$MAIL -s "$SUBJECT" $MAILTO <$BACKUP_TEMP_LOG
Putting double quotes around subject tells the shell to treat it as one parameter.
HTH
-- Rod Hills
There be dragons...
The opinions expressed above are the personal opinions of the authors, not of Hewlett Packard Enterprise. By using this site, you accept the Terms of Use and Rules of Participation.
Company
Events and news
Customer resources
© Copyright 2025 Hewlett Packard Enterprise Development LP