Adding to ghostdog's answerTo store the transformed string into a variable.
Following is what you have to do to change case of aworked for me -
$SOURCE_NAME
to $TARGET_NAME
(upper to lower), inside another shell script:
TARGET_NAME="`echo $SOURCE_NAME | tr '[:upper:]' '[:lower:]'`"