Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我在一列中返回以下值.. 0.250000 和 13.000000。我想将 0.250000 向上舍入到 1 并保持 13 不变。有什么简单的方法可以做到这一点,因为它们都属于同一列?
您的 DBMS 可能具有 CEILING 功能。试试看。
天花板函数会很好地工作,因为您想四舍五入到最接近的整数。有关使用 SQL Server 舍入的更多方法......
SQL Server 舍入方法
从表名中选择 CEILING( 列名 )