Experts in Postgres and Open Source Infrastructure

24x7, 365 Enterprise services since 1997


Professional Postgres and Open Source support

Command Prompt, Inc., is the oldest Postgres Company in North America and one of the oldest Open Source firms still operating today. We serve our clients with best in class expertise and professionalism. You can read more about support and services here:

You have landed at the largest single source of Postgres education blogs in the world. At Command Prompt, we believe deeply that the education of the community is critical to the continued success of Postgres and related technologies. We hope you find content you are looking for and don't hesitate to Contact us today for all your Postgres and Open Source consulting and support needs.

How to Run PostgreSQL and pgAdmin Using Docker

To run PostgreSQL and pgAdmin using Docker, download Postgres and pgAdmin4 images from Docker Hub. Then, build and start the Postgres and pgAdmin4 containers.

How to Use NTH_VALUE Function in PostgreSQL

The NTH_VALUE function in PostgreSQL is used to get the Nth_value from the table using the column and offset to set the value from the column.

How to Install PostgreSQL Using Docker Compose

To install PostgreSQL using Docker Compose, specify the desired services in compose file. Then, start the compose service to build and run Postgres container.

How to Get the Name of the Current User in PostgreSQL

In PostgreSQL, the “CURRENT_USER”, “CURRENT_ROLE”, and “USER” methods are used to get the details of the current user.

What Does SETVAL() Function Do in PostgreSQL?

In PostgreSQL, SETVAL() is one of the sequence functions that resets the current value of the selected sequence and retrieves the specified value.

How to Create a PostgreSQL Database in Docker

To create a PostgreSQL database in Docker, use the “CREATE DATABASE <database-name>;” command. Then, create a new table in it and insert values in the table.

How to Check/Verify if a Specific Table Exists in PostgreSQL Database

In PostgreSQL, the “information_schema”, “pg_catalog”, and “pg_tables” are used to check the existence of a specific table in the current database.

How to Check/Find the Hostname and Port Number in PostgreSQL

In PostgreSQL, several methods are used to check/find the hostnames and port numbers, such as the “\conninfo” command, the “pg_settings” view, etc.

How Do I Get the List of Existing Stored Procedures in PostgreSQL

To get the list of all stored procedures in a database, the “\df” command, “pg_proc” catalog, and “information_schema.routines” view are used in Postgres.

How to Check if a Table Exists in Postgres Database Using a User-Defined Function

In PostgreSQL, a user-defined function can be created that accepts the table name and schema name as arguments.