New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Round(x) Function #458

Closed
Ghalleb opened this Issue Jul 18, 2013 · 4 comments

Comments

Projects
None yet
2 participants
@Ghalleb

Ghalleb commented Jul 18, 2013

I saw there is a round() function that return the closest int from the numeric variable.
But there is no round(x) function that would return the numeric value with x decimal.

For example:

select round(192.4525, 2) -> 192.46
select round(2.3246, 2) -> 2.32 

Some doc here:
http://www.postgresql.org/docs/9.1/static/functions-math.html

@timowest

This comment has been minimized.

Show comment
Hide comment
@timowest

timowest Jul 18, 2013

Member

How well is this supported in other SQL dialects?

Member

timowest commented Jul 18, 2013

How well is this supported in other SQL dialects?

timowest added a commit that referenced this issue Jul 20, 2013

@timowest

This comment has been minimized.

Show comment
Hide comment
@timowest

timowest Jul 20, 2013

Member

Added to MathExpressions

Member

timowest commented Jul 20, 2013

Added to MathExpressions

@timowest

This comment has been minimized.

Show comment
Hide comment
@timowest

timowest Jul 29, 2013

Member

Released in 3.2.2

Member

timowest commented Jul 29, 2013

Released in 3.2.2

@timowest timowest closed this Jul 29, 2013

@timowest timowest added this to the 3.2.2 milestone Apr 14, 2014

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment