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 |
|
RichardEttinger
Starting Member
7 Posts |
Posted - 2004-02-20 : 16:59:22
|
| How can I select fixed values to get rows 1 2 3 and 4??select 1 union select 2 union select 3 union select 4 seems kindof lengthy to produce rows 1 2 3 and 4??If this is the only way how can I order this by ascending as it comes back in miscellaneous orderThanks |
|
|
tkizer
Almighty SQL Goddess
38200 Posts |
Posted - 2004-02-20 : 17:09:27
|
| ORDER BY 1Tara |
 |
|
|
AjarnMark
SQL Slashing Gunting Master
3246 Posts |
Posted - 2004-02-20 : 20:26:39
|
| Richard, are you really looking for the literal values 1, 2, 3, and 4? Or do you want the first 4 rows of data? If the latter, then do something like SELECT TOP 4...--------------------------------------------------------------Find more words of wisdom at [url]http://weblogs.sqlteam.com/markc[/url] |
 |
|
|
ValterBorges
Master Smack Fu Yak Hacker
1429 Posts |
Posted - 2004-02-21 : 00:32:20
|
| Search the site for tally tables. |
 |
|
|
|
|
|