CREATE OR REPLACE FUNCTION myfunc() RETURNS void AS $$
	cnt integer
DECLARE
BEGIN
	EXECUTE 'CREATE TEMPORARY TABLE mytable (col int)';
	SELECT COUNT(*) INTO cnt FROM mytable;
	EXECUTE 'DROP TABLE  mytable';
END;
$$ LANGUAGE plpgsql;
