View Single Post
  #1 (permalink)  
Old 01-25-06, 12:45 PM
kragnesb414 kragnesb414 is offline
New Member
 
Join Date: Dec 2005
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Perl for a dummy

Greetings, new member here.

I have what I believe is a very basic perl scripting question, hopefully someone can point me in the right direction.

First of all some background. I have several years of UNIX scripting experience. The company I work for is moving away from UNIX platforms towards Windows so now I am attempting to use Perl scripts to do the kinds of things in Windows that I used to do in UNIX.

I have O'Reilly's "Camel" book (2nd edition), "Perl Core Language Little Black Book," and "Perl for Dummies." Between these I can usually find information on the Perl equivalent of the UNIX command I am accustomed to. Except for I don't know how to construct a statement to perform multiple actions on an input string. In UNIX I would use a pipe "|". For example, say I wanted to determine the uppercase value of the third character in an input string, in UNIX I would do the following:

STRING=terry
echo $STRING | cut -c 3 | tr [a-z] [A-Z]

How would you recommend constructing a similar statement in Perl?

Thanks,
Terry
Reply With Quote