amazon-redshift-utils icon indicating copy to clipboard operation
amazon-redshift-utils copied to clipboard

v_generate_user_grant_revoke_ddl creates invalid statement.

Open Lalit7523 opened this issue 1 year ago • 0 comments

The output of the v_generate_user_grant_revoke_ddl creates invalid statement because it quotes the object.

ALTER DEFAULT PRIVILEGES for user testuser in schema testschema REVOKE ALL on "tables" FROM testone; ALTER DEFAULT PRIVILEGES for user testuser in schema testschema1 REVOKE ALL on "procedures" FROM testone; ALTER DEFAULT PRIVILEGES for user testuser in schema testschema1 REVOKE ALL on "functions" FROM testone;

The expected output should be objects (tables,procedures,functions) without quotes as below.

ALTER DEFAULT PRIVILEGES for user testuser in schema testschema REVOKE ALL on tables FROM testone; ALTER DEFAULT PRIVILEGES for user testuser in schema testschema1 REVOKE ALL on procedures FROM testone; ALTER DEFAULT PRIVILEGES for user testuser in schema testschema1 REVOKE ALL on functions FROM testone;

Lalit7523 avatar Dec 15 '23 13:12 Lalit7523