i am trying to fetch a value from a string after _ using regex and try to store that value in a variable that i can use somewhere else, like below....also we can have any number in place of 5 like 8, 9 , 10 or 20
my $job = "50.10-d557_5"; my $Path = ""; $path = /home/data/5/file1.log
In reply to regex to extract value from a string by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |