Re: About "ERROR: must be *superuser* to COPY to or from a file"

Поиск
Список
Период
Сортировка
От Douglas McNaught
Тема Re: About "ERROR: must be *superuser* to COPY to or from a file"
Дата
Msg-id m2pss0o1pg.fsf@Douglas-McNaughts-Powerbook.local
обсуждение исходный текст
Ответ на About "ERROR: must be *superuser* to COPY to or from a file"  (Emi Lu <emilu@cs.concordia.ca>)
Ответы Re: About "ERROR: must be *superuser* to COPY to or from a file"  (Greg Stark <gsstark@mit.edu>)
Список pgsql-general
Emi Lu <emilu@cs.concordia.ca> writes:

> Greetings,
>
> I met a question about Copy. I tried to run :
>    copy test(studid) from '/myownDIR/a.txt';
>
> But I got an error as the following:
> ERROR:  must be *superuser* to COPY to or from a file
>
> May I know is it possible that instead of supervuser, regular users
> are able to use COPY as well?

You can use \copy in 'psql' on the client side, but you have to be a
superuser to do COPY on the server side, for security reasons.

If you are not using 'psql' and your client library supports it, you
can use 'COPY FROM stdin' and pass the data across the client
connection.

-Doug

В списке pgsql-general по дате отправления:

Предыдущее
От: vishal saberwal
Дата:
Сообщение: Re: PQConnectdb SSL (sslmode): Is this a bug
Следующее
От: vishal saberwal
Дата:
Сообщение: Re: PQConnectdb SSL (sslmode): Is this a bug