Use XLeratorDB/math for a wide variety of mathematical calculations. The feature-rich XLeratorDB math function library lets you include calculations in any T-SQL statement including SELECT, INSERT, UPDATE, DELETE, CREATE VIEW as well as in CTEs, stored procedures, user-defined functions, and computed columns.
XLeratorDB/math requires Microsoft SQL Server® 2005 or later (which must be purchased separately) . XleratorDB/math installs in minutes and can be used immediately after installation. Anyone familiar with the functions in Microsoft Excel® will immediately feel comfortable with XLeratorDB/math.
Function Reference - Math Functions