Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
| Author |
Topic |
|
chriztoph
Posting Yak Master
184 Posts |
Posted - 2010-03-14 : 21:48:09
|
| how to view all ID even is Skipped?sample in mYtable table i haveID13456810and the output must beID12345678910show the id even it deleted..thanks in advance.. |
|
|
khtan
In (Som, Ni, Yak)
17689 Posts |
Posted - 2010-03-14 : 23:20:01
|
[code]SELECT NUMBERFROM F_TABLE_NUMBER_RANGE(1, 10)ORDER BY NUMBER[/code] KH[spoiler]Time is always against us[/spoiler] |
 |
|
|
chriztoph
Posting Yak Master
184 Posts |
Posted - 2010-03-14 : 23:35:56
|
| is this working for an ID that is varchar in datatype but the inputs are numbers?the ID column properties are IsIdentity = no, allow null = no |
 |
|
|
khtan
In (Som, Ni, Yak)
17689 Posts |
Posted - 2010-03-15 : 00:25:45
|
if your data type varchar and the value is only numeric, you can convert it to integer and use the F_TABLE_NUMBER_RANGESince you basically want to show the complete number range regardless of the number exists or not in your table, you only need to find the max value in the table to pass to the F_TABLE_NUMBER_RANGE KH[spoiler]Time is always against us[/spoiler] |
 |
|
|
chriztoph
Posting Yak Master
184 Posts |
Posted - 2010-03-15 : 01:33:05
|
| thanks.. |
 |
|
|
|
|
|