QuestionQ67

VerifiedUsing Single-Row Functions to Customize Output

Consider the following query:

SQL> SELECT TRUNC(ROUND(156.00, -1), -1)  
FROM DUAL;  

What would the outcome be?

Explanation

In Oracle, a negative precision of -1 rounds or truncates one digit to the left of the decimal point. ROUND(156.00, -1) returns 160, and truncating 160 to that same precision leaves it unchanged at 160.

Learn more

Community Discussion

No comments yet. Be the first to start the discussion!