Setting a session variable for a Postgres connection
Answered
Is it possible to issue the equivalent of either
SELECT set_config('app.current_tenant', '100', false); or
SET app.current_tenant = '100';
So that the value of app.current_tenant can be used for Row Level Security (RS)
Thanks !
Please sign in to leave a comment.
Yes you can do it in Data Source properties -> Options tab -> Startup script. Just put
SET app.current_tenant = '100'
there and restart session.
That worked, thank you