there is always something to develop
How to get a table of X numbered records
The simpliest way to get a table of 100 records numbered 0-99 is to build up a query as bellow. It is easy to extend the amount of records by adding next join sections.
select pm1.Digit+pm2.Digit*10 as Number from( select cast(1 as int) as Digit union select 2 union select 3 union select 4 union select 5 union select 6 union select 7 union select 8 union select 9 union select 0 ) as pm1 inner join ( select cast(1 as int) as Digit union select 2 union select 3 union select 4 union select 5 union select 6 union select 7 union select 8 union select 9 union select 0 ) as pm2 on (1=1)
See also
Comments
"If you don't like something, change it. If you can't change it, change your attitude. "
You are 3610 reader
since 1st April 2009
Yes | 0 | |
No | 0 |