Thursday , April 25 2024

How To Change PostgreSQL User While Connected To The Database

After connecting to the database in PostgreSQL, you may want to change the user you are connected to.

You may want to read the article entitled “How To Connect To Database On PostgreSQL” for how to connect to PostgreSQL.

Change Postgresql User

You can switch to the testuser user from the current user with the command below.

 

What is current user?

You can find the user you are connected to with the command below.

Loading

About dbtut

We are a team with over 10 years of database management and BI experience. Our Expertises: Oracle, SQL Server, PostgreSQL, MySQL, MongoDB, Elasticsearch, Kibana, Grafana.

Leave a Reply

Your email address will not be published. Required fields are marked *

Categories