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 |
|
sica
Posting Yak Master
143 Posts |
Posted - 2001-11-02 : 11:30:45
|
| I have a compute clauses like this one:SELECT type, price, advanceFROM titlesORDER BY typeCOMPUTE SUM(price), SUM(advance)The result is :type price advance ------------ --------------------- --------------------- business 19.9900 5000.0000business 11.9500 5000.0000business 2.9900 10125.0000...trad_cook 20.9500 7000.0000trad_cook 11.9500 4000.0000trad_cook 14.9900 8000.0000UNDECIDED NULL NULL sum =================== 236.2600 sum =================== 95400.0000I want to use an alias on SUM.Is this possible?Do I have to use a temp table ?Thanks!Sica |
|
|
|
|
|