Mega Code Archive

 
Categories / MySQL Tutorial / Math Numeric Functions
 

SIN(X) returns the sine of X, where X is given in radians

mysql> mysql> SELECT SIN(PI()); +----------------------+ | SIN(PI())            | +----------------------+ | 1.2246063538224e-016 | +----------------------+ 1 row in set (0.00 sec) mysql> mysql> SELECT ROUND(SIN(PI())); +------------------+ | ROUND(SIN(PI())) | +------------------+ |                0 | +------------------+ 1 row in set (0.00 sec) mysql>