I'm attempting to initialise my database for a flask app using flask-sqlalchemy.
I've received the following fatal error.
sqlalchemy.exc.OperationalError: (psycopg2.OperationalError) connection to server at "occ-appdc1001" (172.25.208.1), port 5432 failed: FATAL: permission denied to set parameter "log_statement_stats"
My connection string is:
app.config['SQLALCHEMY_DATABASE_URI'] = "postgresql://prodcent_user:XXXXX@SERVER:5432/appdata?options=-search_path=datamanager"
I've tried adding permissions as follows:
GRANT USAGE ON SCHEMA datamanager TO prodcent_user ;
GRANT USAGE ON SCHEMA datamanager TO prodcent_user ;
GRANT SELECT ON ALL TABLES IN SCHEMA datamanager TO prodcent_user ;
GRANT SELECT ON ALL SEQUENCES IN SCHEMA datamanager TO prodcent_user ;
GRANT EXECUTE ON ALL FUNCTIONS IN SCHEMA datamanager TO prodcent_user ;
GRANT ALL ON ALL TABLES IN SCHEMA datamanager TO prodcent_user ;
GRANT ALL ON ALL SEQUENCES IN SCHEMA datamanager TO prodcent_user ;
GRANT ALL ON ALL FUNCTIONS IN SCHEMA datamanager TO prodcent_user ;
But still have the same error.