If I was taking all the digits out (result would be 123400), I would do:

y/0-9//cd;

This takes all the characters not in [0-9] and deletes them.



On Mon, 2004-05-03 at 19:58, William Black wrote:
> Hello All,
> 
> I need a regular expression to extract only the number from the below 
> string.  How is this done?
> 
> x=G1234v00
> 
> Result=1234
> 
> William Black
> 
> _________________________________________________________________
> Stop worrying about overloading your inbox - get MSN Hotmail Extra Storage! 
> http://join.msn.com/?pgmarket=en-us&page=hotmail/es2&ST=1/go/onm00200362ave/direct/01/
-- 
Josà Alves de Castro <[EMAIL PROTECTED]>
Telbit - Tecnologias de InformaÃÃo


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>


Reply via email to