I have a procedure in PostgreSQL:
CREATE OR REPLACE FUNCTION get_geom_difference() RETURNS void AS $$ BEGIN SELECT filedata.num,st_area(ST_Difference(ST_TRAN
In your definition your function returns nothing RETURNS void. If you want num data type just change to RETURNS numeric. Also, To make it worked, perform select into some numeric variable SELECT INTO var and add return var to the end of function.
RETURNS void
RETURNS numeric
SELECT INTO var
return var