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 |
patla4u
Starting Member
10 Posts |
Posted - 2011-08-01 : 16:37:13
|
Hello all,I have following field in report. ID RespID balance Mibalance MaBalance codeGroup 1 Group 10 2000 1 3000 2 5000 3 10000 4 I want a output like : ID RespID balance Mibalance MaBalance codeGroup 1 Group 10 20,000 2,000 18,000 2000 1 3000 2 5000 3 10000 4 I want a output based on code if code=1 then Mibalance =2,000 esle if code in(2,3,4) then 18,000(3000+5000+10000).How can i get Mibalance and Mabalance based on code? |
|
|
|
|