Chce zrobić *create or replace function * ale krzyczy mi taki błąd:
Caused by: org.postgresql.util.PSQLException: BŁĄD: nie można zmieniać zwracanego typu istniejącej funkcji
Szczegóły: Typ rekordu zdefiniowany przez parametr OUT jest inny.
Nie chce robić dropa funkcji, bo wtedy strace uprawnienia, dlaczego po prostu nie pójdzie zwykły replace?
Ale z tego co czytam na stacku, to chyba musze dropa zrobić?
z dokumentacji wynika, że chyba lipa
PostgreSQL 8.4 manual:
To replace the current definition of an existing function, use CREATE OR REPLACE FUNCTION. It is not possible to change the name or argument types of a function this way (if you tried, you would actually be creating a new, distinct function). Also, CREATE OR REPLACE FUNCTION will not let you change the return type of an existing function. To do that, you must drop and recreate the function. (When using OUT parameters, that means you cannot change the names or types of any OUT parameters except by dropping the function.)