Last updated 1 year ago
Constant which represents the PI number (approximately 3.141592...) ().
Math.PI
CREATE OR REPLACE FUNCTION circumference(radius float) RETURNS float LANGUAGE JAVASCRIPT AS $$ function circumference(r){ return 2 * Math.PI * r; } return circumference(RADIUS); $$ ; SELECT CIRCUMFERENCE(2);
CIRCUMFERENCE(2)| ------------------+ 12.566370614359172|