Open Znakes opened 1 year ago
Hello!
I have a very specific situation: my user can't execute
CREATE SCHEMA IF NOT EXISTS schema
from https://github.com/leonibr/community-extensions-cache-postgres/pull/10/commits/3e18e164fa0df5cc06519e57c6a655dff889245a due to insufficient rights. Although schema exists, this command just can't be executed. Therefore I get an exception. But user still have rights to create table! Do you think it is worth to change this query to
IF NOT EXISTS( SELECT schema_name FROM information_schema.schemata WHERE schema_name = '%schema%' ) THEN EXECUTE 'CREATE SCHEMA %schema%'; END IF;
or somehting similar?
Hi, which version of postgres are you in, and what privileges the db user has, but I would rather use CREATE SCHEMA IF NOT EXISTS %schema%, can you check that if it fix in your scenario?
CREATE SCHEMA IF NOT EXISTS %schema%
Hello!
I have a very specific situation: my user can't execute
from https://github.com/leonibr/community-extensions-cache-postgres/pull/10/commits/3e18e164fa0df5cc06519e57c6a655dff889245a due to insufficient rights. Although schema exists, this command just can't be executed. Therefore I get an exception. But user still have rights to create table! Do you think it is worth to change this query to
or somehting similar?