Re: postgresql
| From: | Jason S Motes | Date: | Wed, 14 Apr 2004 20:11:09 +0000 |
| Subject: | Re: postgresql | ||
| References: | 1 | Groups: | php.db |
| Request: | Send a blank email to php-db+get-33884@lists.php.net to get a copy of this message | ||
if i remember correctly you have to do this
su
su postgres
createuser your-user-id
Adam Williams wrote:
Hi, I know this isn't PHP related but I have a quick question about postgresql. I come from a mysql enviroment so I'm a little clueless, even after reading the postgresql docs. I am moving a postgresql database from one server to another. As the user that owns the database, lculber, I ran pg_dump sroom1 > sroom1.database but on the server I'm moving the database to, I can't figure out how to get into psql to create the user lculber so I can do psql sroom1 < sroom1.database so how can I create the users lculber in postgresql. I can't even connect to psql. any advice? :) below is my command. I'm not trying to database root, I just want to get the psql prompt so I can create the user lculber. root@archives1 root]# psql -U root psql: FATAL: Database "root" does not exist in the system catalog. [root@archives1 root]# createuser lculber Shall the new user be allowed to create databases? (y/n) y Shall the new user be allowed to create more new users? (y/n) y psql: FATAL: user "root" does not exist createuser: creation of user "lculber" failed