Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Variable field concatenation

Status
Not open for further replies.

oqurum

Technical User
Jul 20, 2001
14
0
0
GB
I would like to set an environmental variable using a script.
This variable would be run at logon (via the .profile)
and would set a directory for a particular variable.


e.g export YDEBTPGM=/DebtMan/LIVE/progs

I was wondering , for release purposes, if I could concatenate another file to this variable - such as

export YDEBTPGM=/DebtMan/LIVE/progs:/DebtMan/NEW/progs

Any ideas ?












I'M NOT WAVING I'M DROWNING
 
export a='PATH=$PATH:/DebtMan/LIVE/progs;/DebtMan/NEW/progs'

But I dont see the point

Just set two

export YDEBTPGMLIVE=/DebtMan/LIVE/progs
export YDEBTPGMNEW=/DebtMan/NEW/progs



--
| Mike Nixon
| Unix Admin
| ----------------------------
 
Yes you ca do that but as mike suggested, why not use different variables. Cleaner I think?

Adam
 
Thanks for the responses guys

But the YDEBTPGM variable is within an application and cant be changed !!

I may use your fist suggestion as regards the use of the PATH

Most obliged..
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top