in reply to cut a string in a string

If you are matching many instances of this (say reading a log file that is 700MB or more and checking each line for this string) then you are likely to find that the performance improves if you:
use strict; use warnings; my $line = "SNMPv2-MI::enterprises.343.2.10.3.5.100.1.0=INT"; my $match = $1 if $line =~ /^SNMPv2-MI::enterprises([0-9\.]+)=INT$/;