I have a transaction group logging a string from a weigh scale. The data comes back as “109.55 lb Under” I want to strip out “lb Under” and just log the weight.
I have a query that will select the data like I need but would rather just put the data in the table like I need it to begin with.
select avg(substring_index(`weight`,' ',5)) as average from line_2_pallet
Is there an expression script that can maybe do this? The string coming back will always have the same ending pattern " lb Under".