Disable script execution in server level when updating via grids

Started by arun chirappurathover 2 years ago2 messagesgeneral
Jump to latest
#1arun chirappurath
arunsnmimt@gmail.com

Hello All,

Is there a way we can disable grid based updates from the clients in the
server?

suppose if someone accidentally commits an edit in dbeaver,server shall
decline that incoming request. However requests from the query tool should
run....

I have seen some options from the client side. Do we have some options in
server side?

[image: image.png]

Thanks,
Arun

Attachments:

image.pngimage/png; name=image.pngDownload
#2Filip Sedlák
filip@sedlakovi.org
In reply to: arun chirappurath (#1)
Re: Disable script execution in server level when updating via grids

I'd use different users or roles for that - one with more restricted
rights. I'm not sure how to do it in your specific client.

In general, your user can be granted be granted read-only access and a
more powerful role to which it can switch explicitly.

mydb=> CREATE TABLE x (id INT);
ERROR: permission denied for schema public
LINE 1: CREATE TABLE x (id INT);
^
mydb=> SET ROLE powerful;
SET
mydb=> CREATE TABLE x (id INT);
CREATE TABLE

In PostgreSQL up to 15, you have to set "NOINHERIT" to your user so you
don't automatically get all the privileges on login. In 16, you can set
INHERIT FALSE when granting the role.

--
Filip Sedlák