I have recently had a database table change which has grouped three table values in one column. The new column holds the 3 values and delimits them with ~
(Eg. Col Name: OL_From Value: 2~7548~186)
My old query was using the second value as an index for a left join but now I need to parse out the value and serve it up for as a value for the left join.
The old query looked like
left join run r2 on sr.from_run_id = r2.run_id
However now the "from_run_id" field no longer exists as it is the second value of the above example (Eg. 2~7548~186)
splitting the string up with string_split seems easy enough but how do I then retrieve my second value and serve it back to the join.
Thanks for your time.