I found this function which returns three rows for the following query:
select * from dbo.split('1 2 3',' ')
However, I need to use values from a field instead of '1 2 3'.
I tried:
select * from dbo.split(select top 1 myfield from mytable,' ')
But it fails saying incorrect syntax.
Ideas on how to do this? It doesn't have to use the function above, so feel free to recommend another function or different way to go about it. To clarify, I only need to parse the values from a single row of a single field.