Using oracle SQL I want to generate a string list of numbers counting up to a quantity value.
Select [Item], [Quantity], <Something here> as [Quantity List]
from table
to return
[Item],[Quantity], [Quantity List]
'Socks', 2 , '1 2'
'Shoes', 3 , '1 2 3'
'Coats', 6 , '1 2 3 4 5 6'
'Hats' , 3 , '1 2 3' etc...
I'm not trying to create a reference table, each quantity needs to be evaluated and appropriate string put in as it runs Thanks in advance