Re: [GENERAL] ownership of DBs and tables?
От | Jim Richards |
---|---|
Тема | Re: [GENERAL] ownership of DBs and tables? |
Дата | |
Msg-id | 200002170322.WAA15509@hub.org обсуждение исходный текст |
Ответ на | ownership of DBs and tables? (Louis Bertrand <louis@bertrandtech.on.ca>) |
Ответы |
Re: [GENERAL] ownership of DBs and tables?
Re: [GENERAL] ownership of DBs and tables? |
Список | pgsql-general |
At 09:58 PM 16/02/00 -0500, you wrote: >Is there a way of changing the ownership of tables and even entire >databases? Um, after the table has been created no, but you can set up users and accounts, so as you, try (in ksh, not sure about others) PGUSER=postgres PGPASSWORD=postgres psql template1 then create user www with password "www"; then when you want to run scripts, or connect then you can with PGUSER=www PGPASSSWORD=www psql -f filename.sql webdb or interactively PGUSER=www PGPASSSWORD=www psql webdb >\i filename.sql >Here's why I ask. I created a database "webdb" for a PHP3 application and >created a database user "www" to own it. However, I am creating the actual >tables as user "louis" who has superuser privileges in PostgreSQL. When >I look at the ownership of a new table, it's "louis", not "www". I'm >doing this with psql and pgaccess. I'd rather not have to su(8) as >"www" to perform DB maintenance. -- An army marches as fast as its slowest stomach. Mr Grumpy - what are you on about? http://www.cyber4.org/members/grumpy/index.html
В списке pgsql-general по дате отправления: