Skip to content

Commit 1b8b94d

Browse files
Fix error: Cannot execute SQL 'SELECT proacl::text FROM pg_catalog.pg… (#783)
* Fix error: Cannot execute SQL 'SELECT proacl::text FROM pg_catalog.pg_proc WHERE proname = ANY (%s) ORDER BY proname, proargtypes': syntax error at or near "%" * Fix error: Cannot execute SQL 'SELECT proacl::text FROM pg_catalog.pg_proc WHERE proname = ANY (%s) ORDER BY proname, proargtypes': syntax error at or near "%" * Update changelogs/fragments/783-fix-postgresql-privs-not-specified-schema.yml Co-authored-by: Andrew Klychkov <aaklychkov@mail.ru> --------- Co-authored-by: Andrew Klychkov <aaklychkov@mail.ru>
1 parent 6d12f71 commit 1b8b94d

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
bugfixes:
2+
- postgresql_privs - fix the error occurring when trying to grant a function execution and set the schema to not-specified (https://github.com/ansible-collections/community.postgresql/pull/783).

plugins/modules/postgresql_privs.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -658,7 +658,7 @@ def get_function_acls(self, schema, function_signatures):
658658
else:
659659
query = ("SELECT proacl::text FROM pg_catalog.pg_proc WHERE proname = ANY (%s) "
660660
"ORDER BY proname, proargtypes")
661-
self.execute(query)
661+
self.execute(query, (funcnames))
662662
return [t["proacl"] for t in self.cursor.fetchall()]
663663

664664
def get_schema_acls(self, schemas):

0 commit comments

Comments
 (0)