Posted inSQL
Microsoft
9 years ago
Create a generate_series table value function
Postgres has this function and it can be very useful.The generateseries(start, stop, step) will return a single column of table from start to stop incremented by step inclusively. (e.g. 1 to 10, step 2 will return 1,3,5,7,9). Postgres also offers an overload that supports date incremented by an interval, although that can be emulated effectively by::select dateadd(d,n,@myStartDate) from generateseries(0,100,1) f(n)
Completed
ProgrammabilitySuggestionsCompleted
Company Response
Microsoft
Company Response
1 year agoVote
2 Comments