I'm trying to remove everything in the %BPM% field (which for example contains "00319 BPM") except "319"
Currently the value field in the bpm column contains "$regexp(%bpm%,([1-9]+),$)" (without the quotes of course)
But it's printing a long error message about the + operator.
"$regexp(%bpm%,[1-9]+,$0)"
But there is still a flaw. You only want to knock out the leading zeros. Don't you?
"$regexp(%bpm%,[1-9][0-9]*,$0)"
You do not need a regular expression, a simple standard function can help too ...
$num('00123 BPM',0) ==> '123'
$num('00120 BPM',0) ==> '120'
$num(%BPM%,0)
If you want a regular expression ...
$regexp(%BPM%,'0*(\d+).*','$1')
DD.20160325.1827.CET
Thanks @DetlevD the $num() function worked perfectly.
For anyone coming from Google the solution was: $num(%bpm%,)