Experts in Postgres and Open Source Infrastructure

24x7, 365 Enterprise services since 1997

Education

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.

PostgreSQL SPLIT_PART Function: Extracting Data From a String

The SPLIT_PART() function accepts three arguments: a string, a delimiter/separator, and a position. Consequently, it retrieves the extracted data from the given string.

How to Group by Date/Time in PostgreSQL

PostgreSQL offers various built-in functions to group data by time, such as the DATE_TRUNC(), EXTRACT(), and DATE_PART() functions.

PostgreSQL Logical Operators: AND, OR, NOT

PostgreSQL has three main logical operators: OR, AND, and NOT. All these operators retrieve a boolean value and are hence also referred to as Boolean operators.

How to Drop a Default Value From a Column in PostgreSQL

To drop/remove the default value from a column, you need to use the “DROP DEFAULT” keyword with the assistance of the “ALTER TABLE” command.

INTEGER Data Types in PostgreSQL

PostgreSQL provides several integer data types, such as INTEGER, SMALLINT, and BIGINT. These data types assist us in storing and manipulating whole numbers.

How to Drop a View in PostgreSQL

In Postgres, the DROP VIEW statement allows us to delete one or more views from a database. To do that, use the DROP VIEW statement followed by the view’s name to be deleted.

How the timezone() Function Works in PostgreSQL

In PostgreSQL, the timezone() function converts a timestamp to a different time zone. It retrieves a new timestamp with the same value but in a different time zone.

How to Extract DATE From a TIMESTAMP in PostgreSQL?

In PostgreSQL, the built-in DATE() function, CAST operator, and scope resolution operator “::” are used to extract a date from a TIMESTAMP.

How to Change the Timezone of a Postgres Database

PostgreSQL provides an “ALTER DATABASE” command that is used with the “SET TIMEZONE” clause to change the timezone of a Postgres database.

GREATEST() and LEAST() Functions in PostgreSQL

In PostgreSQL, the GREATEST() and LEAST() are built-in functions used to get the biggest and smallest value from the given data, respectively.