Hi,
I wan to use "COPY INTO table from 'file'" SQL instruction with a user
rather than monetdb. This user needs the administrator rights. So far I
have done these using monetdb user as the login:
CREATE USER "mdb_user" WITH PASSWORD '"password"' NAME 'Test db user'
SCHEMA "sys";
CREATE ROLE "testdbadmin" WITH ADMIN CURRENT_USER;
GRANT "testdbadmin" TO "mdb_user" WITH ADMIN OPTION;
CREATE SCHEMA "testdb" AUTHORIZATION "mdb_user";
ALTER USER "mdb_user" SET SCHEMA "testdb";
I learnt this from MonetDB UserGuide tutorial and from MonetDB
authorisation documentation. However, I still cannot use 'mdb_user' for
COPY INTO from file command. What is missing? What does 'ADMIN OPTION'
do? How to make 'mdb_user' have the same right as monetdb?
At the moment, I'm using monetdb user directly. But, it would be a bit
nicer to have a different username. I'm working on a web service
connecting to 3 different databases: mysql, postgres and now monetdb.
They have a common username for the database connection. If I keep using
monetdb user, the commonality rule is broken. I have another to use
'mdb_user' via STDIN and piping, but exporting DOTMONETDBFILE as an
environment variable to make mclient login with out asking for password
is another complexity dimension.
Making mdb_user to have administrator rights like monetdb is the best
option for me if this is possible, and I hope this is possible.
Regards,
Puthick