Trunc function truncates number to specified decimals

Synatx :

TRUNC(m,[n]) – Truncates to n decimal. n is optional

Examples:-

SQL> select trunc(25.48,1) from dual;

TRUNC(25.48,1)
————–
25.4

SQL> select trunc(25.4,1) from dual;

TRUNC(25.4,1)
————-
25.4

SQL> select trunc(25.6,1) from dual;

TRUNC(25.6,1)
————-
25.6

some more ….

trunc(25.6,-1) returns 20
trunc(25.6,0) returns 25
trunc(25.65,1) returns 25.6
trunc(25.45,0) returns 25