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
 General SQL Server Forums
 New to SQL Server Programming
 displaying variable values

Author  Topic 

bill_
Starting Member

38 Posts

Posted - 2010-05-17 : 18:07:15
How do you display variable values ?

Trying to learn how to loop through a cursor and take totals and counts.

Tried the PRINT @totalfee but when I did exec mystoredproc I saw query results but no total.

visakh16
Very Important crosS Applying yaK Herder

52326 Posts

Posted - 2010-05-18 : 01:01:39
print willl display results in messages tab

------------------------------------------------------------------------------------------------------
SQL Server MVP
http://visakhm.blogspot.com/

Go to Top of Page

dattatreysindol
Starting Member

20 Posts

Posted - 2010-05-18 : 05:16:25
Hi There -

You can even use SELECT @totalfee to display the results in the results tab.


Dattatrey Sindol
http://mytechnobook.blogspot.com/

This information is provided "AS IS" with no warranties, and confers no rights.
Go to Top of Page

bill_
Starting Member

38 Posts

Posted - 2010-05-18 : 08:14:06
Thank you very much visakh16 and dattareysindol !
Go to Top of Page

visakh16
Very Important crosS Applying yaK Herder

52326 Posts

Posted - 2010-05-18 : 13:54:36
welcome

------------------------------------------------------------------------------------------------------
SQL Server MVP
http://visakhm.blogspot.com/

Go to Top of Page
   

- Advertisement -