Bug in SQL Tutorial

Describe your issue

ROUND()

Let us introduce the ROUND() function as it is routinely used with aggregate functions.
Sql uses the ROUND() functions to display numeric values rounded to a specified precision.
The precision parameter indicates the number of decimal places to which the number should be rounded.

The ROUND() function requires two parameters enclosed in parentheses: a column name and an integer value.
Below is the query to display Total_Purchase rounded to 1 decimal place from the table customer

the output shown is 21.34 but output according to codechef is 21.35 which is incorrect

Screenshot

Additional info

SELECT ROUND(Taxable_Pay, 2) as ‘taxable_pay’
FROM employee;

Thanks for reporting. This is fixed.

1 Like