Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

application_name is not being saved in the audit.log table #7

Open
paulovieira opened this issue Jul 1, 2022 · 0 comments
Open

application_name is not being saved in the audit.log table #7

paulovieira opened this issue Jul 1, 2022 · 0 comments

Comments

@paulovieira
Copy link
Contributor

I noticed that application_name is not being saved. Turns out the call to current_setting has a wrong setting_name parameter: instead of

current_setting('audit.application_name', true)

it should be simply

current_setting('application_name', true)

https://github.com/m-martinez/pg-audit-json/blob/master/sql/pg-audit-json--1.0.2.sql#L223-L224

More details about application_name: https://www.postgresql.org/docs/current/runtime-config-logging.html#GUC-APPLICATION-NAME

By the way, the other setting the is supposed to be saved (application_user_name) doesn't seem to be valid.

Thanks for this nice tool!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant