-- -- apm_service__delete/1 -- create or replace function apm_service__delete( integer ) returns int4 as $$ declare delete__service_id alias for $1; begin delete from apm_services where service_id = delete__service_id; PERFORM apm_package__delete( delete__service_id ); return 0; end;$$ language plpgsql;