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.

 All Forums
 SQL Server 2000 Forums
 SQL Server Development (2000)
 SQL Related(Result without using SUM())

Author  Topic 

AskSQLTeam
Ask SQLTeam Question

0 Posts

Posted - 2004-07-06 : 12:06:05
Chiranjib writes "Pls, tell me is it possible to write a single SQL Statement which will sum the numeric values of a column in a table without using SUM() function provided in MS-SQL?"

Seventhnight
Master Smack Fu Yak Hacker

2878 Posts

Posted - 2004-07-06 : 12:09:47
Gotta be homework...

Does this count??

Declare @myVar int
Select @myVar = isnull(@myVar,0) + columnName From myTable


Corey
Go to Top of Page
   

- Advertisement -