Skip to content

Commit 05137fa

Browse files
committed
Merge pull request 2ndQuadrant#16 from memoz/master
Fix quote_ident(regclass)
2 parents 341d504 + b798498 commit 05137fa

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

audit.sql

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -186,15 +186,15 @@ DECLARE
186186
_q_txt text;
187187
_ignored_cols_snip text = '';
188188
BEGIN
189-
EXECUTE 'DROP TRIGGER IF EXISTS audit_trigger_row ON ' || quote_ident(target_table);
190-
EXECUTE 'DROP TRIGGER IF EXISTS audit_trigger_stm ON ' || quote_ident(target_table);
189+
EXECUTE 'DROP TRIGGER IF EXISTS audit_trigger_row ON ' || quote_ident(target_table::TEXT);
190+
EXECUTE 'DROP TRIGGER IF EXISTS audit_trigger_stm ON ' || quote_ident(target_table::TEXT);
191191

192192
IF audit_rows THEN
193193
IF array_length(ignored_cols,1) > 0 THEN
194194
_ignored_cols_snip = ', ' || quote_literal(ignored_cols);
195195
END IF;
196196
_q_txt = 'CREATE TRIGGER audit_trigger_row AFTER INSERT OR UPDATE OR DELETE ON ' ||
197-
quote_ident(target_table) ||
197+
quote_ident(target_table::TEXT) ||
198198
' FOR EACH ROW EXECUTE PROCEDURE audit.if_modified_func(' ||
199199
quote_literal(audit_query_text) || _ignored_cols_snip || ');';
200200
RAISE NOTICE '%',_q_txt;

0 commit comments

Comments
 (0)