diff --git a/uninstall_api.sql b/uninstall_api.sql index 4e964bc..468a40d 100644 --- a/uninstall_api.sql +++ b/uninstall_api.sql @@ -1,17 +1,8 @@ -DROP FUNCTION IF EXISTS v1.google_translate(char, char, text); -DROP FUNCTION IF EXISTS v1.google_translate_array(char, char, json); +revoke execute on function v1.google_translate(char, char, text) from apiuser; +revoke execute on function v1.google_translate_array(char, char, json) from apiuser; +drop function v1.google_translate(char, char, text); +drop function v1.google_translate_array(char, char, json); +--revoke usage on schema v1 from apiuser; +--drop schema v1 cascade; +--drop role apiuser; -DROP FUNCTION IF EXISTS v1.promt_translate(char, char, text); -DROP FUNCTION IF EXISTS v1.promt_translate_array(char, char, json); - -DROP FUNCTION IF EXISTS v1.bing_translate(char, char, text); -DROP FUNCTION IF EXISTS v1.bing_translate_array(char, char, json); --- revoke usage on schema v1 from apiuser; --- drop schema v1 cascade; --- drop role apiuser; - -DROP FUNCTION IF EXISTS v2.translate_array(CHAR(2), CHAR(2), JSON) - --- REVOKE USAGE ON SCHEMA v2 FROM apiuser; --- DROP SCHEMA v2 CASCADE; --- DROP ROLE apiuser; \ No newline at end of file