I have a filename like PT.3_BUSHING-212389.csv
The only thing that is consistent is that a "-" comes before the number and a "." comes after.
How can I extract the 212389 to use in a variable.
I have tried
echo "PT.3_BUSHING-212389.csv" | sed -n '/-/,/./p'
thanks,
Jeff
The only thing that is consistent is that a "-" comes before the number and a "." comes after.
How can I extract the 212389 to use in a variable.
I have tried
echo "PT.3_BUSHING-212389.csv" | sed -n '/-/,/./p'
thanks,
Jeff