Beefy Boxes and Bandwidth Generously Provided by pair Networks
Do you know where your variables are?
 
PerlMonks  

Re: extract part of line

by bjelli (Pilgrim)
on Jul 14, 2002 at 11:58 UTC ( #181564=note: print w/ replies, xml ) Need Help??


in reply to extract part of line

Use substr:

substr - get or alter a portion of a string 

SYNOPSIS:
=========
substr EXPR,OFFSET,LEN,REPLACEMENT 
substr EXPR,OFFSET,LEN 
substr EXPR,OFFSET 

DESCRIPTION:
============
Extracts a substring out of EXPR and returns it. 

There's a nice article about it at developer daily. If you want to learn more about handling fixed with data I recommend David Cross's book Data Munging with Perl

--
Brigitte    'I never met a chocolate I didnt like'    Jellinek
http://www.horus.com/~bjelli/         http://perlwelt.horus.at


Comment on Re: extract part of line

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://181564]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others about the Monastery: (8)
As of 2015-07-07 11:41 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (88 votes), past polls