Please start any new threads on our new site at We've got lots of great SQL Server experts to answer whatever question you can come up with.

Our new SQL Server Forums are live! Come on over! We've restricted the ability to create new threads on these forums.

SQL Server Forums
Profile | Active Topics | Members | Search | Forum FAQ
Register Now and get your question answered!
Save Password
Forgot your Password?

 All Forums
 General SQL Server Forums
 New to SQL Server Programming
 to find the division and result
 Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

Starting Member

1 Posts

Posted - 02/23/2013 :  23:18:22  Show Profile  Reply with Quote
if student get 430 marks out of 600 marks then how to find percentage,
division and result


Flowing Fount of Yak Knowledge

United Kingdom
2179 Posts

Posted - 02/24/2013 :  02:42:37  Show Profile  Visit jackv's Homepage  Reply with Quote
This would give you the answer, but overall ,if this is part of an application, i'd complete at the presentation layer

declare @total decimal(10,2),@part decimal (10,2)
set @total = 600
set @part = 430

select (100 /@total) * @part

Jack Vamvas
Go to Top of Page

Very Important crosS Applying yaK Herder

52326 Posts

Posted - 02/24/2013 :  23:25:56  Show Profile  Reply with Quote
marks*100.0/totalmarks should give you percentage

SQL Server MVP

Go to Top of Page
  Previous Topic Topic Next Topic  
 Reply to Topic
 Printer Friendly
Jump To:
SQL Server Forums © 2000-2009 SQLTeam Publishing, LLC Go To Top Of Page
This page was generated in 0.05 seconds. Powered By: Snitz Forums 2000