py_sleep postgres function

This commit is contained in:
Simon Martín 2017-11-17 13:09:37 +01:00
parent 2211e7c0ed
commit 3a5c28cced

View File

@ -0,0 +1,5 @@
CREATE OR REPLACE FUNCTION py_sleep(t FLOAT8)
RETURNS void AS $$
import time
time.sleep(t)
$$ LANGUAGE plpythonu;