pg.ddx.io  pgsql-general@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Adrian Klaver <adrian.klaver@aklaver.com>
To: Amn Ojee Uw <amnojeeuw@gmail.com>
To: pgsql-general@lists.postgresql.org
Subject: Re: PostgreSQL - How to login with my Linux user account
Date: Thu, 27 Jul 2023 17:31:54 -0700
Message-ID: <943ea752-bf4a-bcba-d2c5-95cfd31e2733@aklaver.com> (raw)
In-Reply-To: <ae4781f7-5221-0ea3-e2ed-611bd5078409@gmail.com>
References: <ae4781f7-5221-0ea3-e2ed-611bd5078409@gmail.com>

On 7/27/23 17:19, Amn Ojee Uw wrote:
> I'd like to log into my newly installed PostgreSQL [ PostgreSQL 12.15 
> (Debian 12.15-1.pgdg120+1) ] using my linux account.
> In trying to do that this web page 
> <https://alvinalexander.com/blog/post/postgresql/log-in-postgresql-database/>suggest that I enter :
> 
> psql -d mydb -U myuser -W
> 
> However, that command requires a database_name (mydb), and PosgreSQL 12.15 being so freshly installed does not yet
> have any database created by me.
> 
> How would you suggest I circumvent this challenge?

The tutorial

https://www.postgresql.org/docs/current/tutorial.html

would be a good place to start.

 From said tutorial:

https://www.postgresql.org/docs/current/tutorial-createdb.html

createdb mydb


Which in turn leads to:

https://www.postgresql.org/docs/current/app-createdb.html

> 
> Mind you that, using the postgres account I have created other accounts.
> 
> 
> Role name |                         Attributes                         | Member of
> -----------+------------------------------------------------------------+-----------
>   chispa    | Superuser                                                  | {}
>   pedro     | Superuser                                                  | {}
>   postgres  | Superuser, Create role, Create DB, Replication, Bypass RLS | {}
> 
> 
> Thanks in advance.
> 

-- 
Adrian Klaver
adrian.klaver@aklaver.com






view thread (6+ messages)  latest in thread

Message-ID: <943ea752-bf4a-bcba-d2c5-95cfd31e2733@aklaver.com>
Permalink:  ../943ea752-bf4a-bcba-d2c5-95cfd31e2733@aklaver.com/
Also on:    postgresql.org/message-id/943ea752-bf4a-bcba-d2c5-95cfd31e2733@aklaver.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-general@postgresql.org
  Cc: adrian.klaver@aklaver.com, amnojeeuw@gmail.com
  Subject: Re: PostgreSQL - How to login with my Linux user account
  In-Reply-To: <943ea752-bf4a-bcba-d2c5-95cfd31e2733@aklaver.com>
  References: <ae4781f7-5221-0ea3-e2ed-611bd5078409@gmail.com> <943ea752-bf4a-bcba-d2c5-95cfd31e2733@aklaver.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox