May 20, 2002 #1 hronek MIS Nov 1, 2001 14 US I am trying to capitilize a string in a ksh script and can not figure out how to do so. Can anyone help me? Thank you, Steven Hronek
I am trying to capitilize a string in a ksh script and can not figure out how to do so. Can anyone help me? Thank you, Steven Hronek
May 20, 2002 Thread starter #2 hronek MIS Nov 1, 2001 14 US A friend just figured it out This is an example. > LSTR=abc;CSTR=`echo $LSTR | tr '[:lower:]' '[:upper:]' `;echo $CSTR >ABC Upvote 0 Downvote
A friend just figured it out This is an example. > LSTR=abc;CSTR=`echo $LSTR | tr '[:lower:]' '[:upper:]' `;echo $CSTR >ABC
May 22, 2002 #3 dobbyn Programmer Jan 23, 2002 120 US An easier way is to typeset your variable. In ksh: typeset -u VAR VAR=test echo $VAR produces the output "TEST" Upvote 0 Downvote
An easier way is to typeset your variable. In ksh: typeset -u VAR VAR=test echo $VAR produces the output "TEST"