Skip to main content

2 posts tagged with "MySql"

Related to MySql

View All Tags

PostgreSQL Data Types

· 3 min read
Mahmudur Rahman
Founder of EpicLabs23

PostgreSQL offers a wide range of data types that can be broadly categorized as follows:


1. Numeric Types

  • Small Integer: SMALLINT (2 bytes, range: -32,768 to +32,767)
  • Integer: INTEGER or INT (4 bytes, range: -2,147,483,648 to +2,147,483,647)
  • Big Integer: BIGINT (8 bytes, range: -9,223,372,036,854,775,808 to +9,223,372,036,854,775,807)
  • Decimal/Numeric: DECIMAL(p, s) or NUMERIC(p, s) (User-defined precision)
  • Real: REAL (4 bytes, single-precision floating-point)
  • Double Precision: DOUBLE PRECISION (8 bytes, double-precision floating-point)
  • Serial: SERIAL, BIGSERIAL, SMALLSERIAL (Auto-incrementing integers)