Home > MS SQL > Round A Number In MS SQL

Round A Number In MS SQL

November 10th, 2008 Leave a comment Go to comments

To round a number in MS SQL use the ROUND() function. This function takes two parameters, the first is the number to be rounded and the second is the number of decimal places to round the number to. Here is an example of rounding the numbers in a column to the nearest whole integer.

SELECT ROUND(table.column1,0) rentValue FROM table

Categories: MS SQL Tags: , , , , ,
  1. No comments yet.
  1. No trackbacks yet.