I think I have created a stored procedure using the following:
CREATE FUNCTION select_all_employee_demographics()
RETURNS REFCURSOR
LANGUAGE plpgsql
AS $$
DECLARE
cur REFCURSOR;
BEGIN
OPEN cur FOR SELECT * FROM EmployeeDemographics;
RETURN cur;
END;
$$;
Then I tried to delete the saved functions using the following:
DROP FUNCTION get_employee_demographics(refcurser);
DROP FUNCTION select_all_employee_demographics;
But I get the following errors:
"could not find a function named "select_all_employee_demogrphics"
Please also see attached image of my environment.
Please let me know if i need to specify further.
2
Answers
This piece of code worked, specific to my issue.
Thank you all for helping - appreciate it
Try to drop the function without inputs, like this:
references: PostgreSQL Drop Function