osx - Postgres : Change current user to root -
complete database newbie here. installed postgres on laptop run local apps , stuff. fact postgres setup using myname
instead of root
quite hinderance. way cant replace root
?
i open psql
this:
psql -h localhost
myname=# \l list of databases name | owner | encoding | collate | ctype | access privileges --------------+--------------+----------+-------------+-------------+------------------------------- myname | myname | utf8 | en_us.utf-8 | en_us.utf-8 | pixelmanager | myname | utf8 | en_us.utf-8 | en_us.utf-8 | postgres | myname | utf8 | en_us.utf-8 | en_us.utf-8 | template0 | myname | utf8 | en_us.utf-8 | en_us.utf-8 | =c/myname + | | | | | myname=ctc/myname template1 | myname | utf8 | en_us.utf-8 | en_us.utf-8 | =c/myname + | | | | | myname=ctc/myname (5 rows)
thanks help
simply set 2 default databases (template1
/ template0
) user want, , future / new databases created new user.
for e.g.
alter database template0 owner newname1; alter database template1 owner newname1;
Comments
Post a Comment