Question

I have the following values being returned in a column.. 0.250000 and 13.000000. I'd like to round the 0.250000 up to 1 and leave the 13 as is. Any easy way to do this since they both fall within the same column?

Was it helpful?

Solution

Your DBMS probably has a CEILING function. Try that.

OTHER TIPS

The ceiling function will work well because you want to round to the nearest whole number. For more methods on rounding with SQL Server....

SQL Server Rounding Methods

select CEILING( columnname ) from tablename

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top