pg_analytics

pg_analytics

Postgres for analytics, powered by DuckDB

Overview

IDExtensionPackageVersionCategoryLicenseLanguage
2420
pg_analytics
pg_analytics
0.3.7
OLAP
PostgreSQL
Rust
AttributeHas BinaryHas LibraryNeed LoadHas DDLRelocatableTrusted
--s-dt-
No
Yes
No
Yes
no
yes
Relationships
See Also
pg_duckdb
pg_mooncake
duckdb_fdw
pg_parquet
columnar
citus_columnar
orioledb
citus

archived, no longer maintained

Packages

TypeRepoVersionPG Major AvailabilityPackage PatternDependencies
EL
PIGSTY
0.3.7
18
17
16
15
14
13
pg_analytics_$v-
Debian
PIGSTY
0.3.7
18
17
16
15
14
13
postgresql-$v-pg-analytics-
Linux / PGPG18PG17PG16PG15PG14PG13
el8.x86_64
MISS
PIGSTY 0.3.7
PIGSTY 0.3.7
PIGSTY 0.3.7
PIGSTY 0.3.7
PIGSTY 0.2.1
el8.aarch64
MISS
PIGSTY 0.3.7
PIGSTY 0.3.7
PIGSTY 0.3.7
PIGSTY 0.3.7
PIGSTY 0.2.1
el9.x86_64
MISS
PIGSTY 0.3.7
PIGSTY 0.3.7
PIGSTY 0.3.7
PIGSTY 0.3.7
PIGSTY 0.2.1
el9.aarch64
MISS
PIGSTY 0.3.7
PIGSTY 0.3.7
PIGSTY 0.3.7
PIGSTY 0.3.7
PIGSTY 0.2.1
el10.x86_64
MISS
MISS
MISS
MISS
MISS
MISS
el10.aarch64
MISS
MISS
MISS
MISS
MISS
MISS
d12.x86_64
MISS
PIGSTY 0.3.7
PIGSTY 0.3.7
PIGSTY 0.3.7
PIGSTY 0.3.7
MISS
d12.aarch64
MISS
PIGSTY 0.3.7
PIGSTY 0.3.7
PIGSTY 0.3.7
PIGSTY 0.3.7
MISS
d13.x86_64
MISS
MISS
MISS
MISS
MISS
MISS
d13.aarch64
MISS
MISS
MISS
MISS
MISS
MISS
u22.x86_64
MISS
PIGSTY 0.3.7
PIGSTY 0.3.7
PIGSTY 0.3.7
PIGSTY 0.3.7
MISS
u22.aarch64
MISS
PIGSTY 0.3.7
PIGSTY 0.3.7
PIGSTY 0.3.7
PIGSTY 0.3.7
MISS
u24.x86_64
MISS
PIGSTY 0.3.7
PIGSTY 0.3.7
PIGSTY 0.3.7
PIGSTY 0.3.7
MISS
u24.aarch64
MISS
PIGSTY 0.3.7
PIGSTY 0.3.7
PIGSTY 0.3.7
PIGSTY 0.3.7
MISS
PackageVersionOSORGSIZEFile URL
pg_analytics_170.3.7el8.x86_64pigsty11.1 MiBpg_analytics_17-0.3.7-1PARADEDB.el8.x86_64.rpm
pg_analytics_170.3.7el8.aarch64pigsty9.7 MiBpg_analytics_17-0.3.7-1PARADEDB.el8.aarch64.rpm
pg_analytics_170.3.7el9.x86_64pigsty11.1 MiBpg_analytics_17-0.3.7-1PARADEDB.el9.x86_64.rpm
pg_analytics_170.3.7el9.aarch64pigsty10.2 MiBpg_analytics_17-0.3.7-1PARADEDB.el9.aarch64.rpm
postgresql-17-pg-analytics0.3.7d12.x86_64pigsty10.2 MiBpostgresql-17-pg-analytics_0.3.7_amd64.deb
postgresql-17-pg-analytics0.3.7d12.aarch64pigsty8.8 MiBpostgresql-17-pg-analytics_0.3.7_arm64.deb
postgresql-17-pg-analytics0.3.7u22.x86_64pigsty10.3 MiBpostgresql-17-pg-analytics_0.3.7_amd64.deb
postgresql-17-pg-analytics0.3.7u22.aarch64pigsty9.0 MiBpostgresql-17-pg-analytics_0.3.7_arm64.deb
postgresql-17-pg-analytics0.3.7u24.x86_64pigsty10.6 MiBpostgresql-17-pg-analytics_0.3.7_amd64.deb
postgresql-17-pg-analytics0.3.7u24.aarch64pigsty9.2 MiBpostgresql-17-pg-analytics_0.3.7_arm64.deb
PackageVersionOSORGSIZEFile URL
pg_analytics_160.3.7el8.x86_64pigsty11.1 MiBpg_analytics_16-0.3.7-1PARADEDB.el8.x86_64.rpm
pg_analytics_160.3.7el8.aarch64pigsty9.7 MiBpg_analytics_16-0.3.7-1PARADEDB.el8.aarch64.rpm
pg_analytics_160.3.7el9.x86_64pigsty11.1 MiBpg_analytics_16-0.3.7-1PARADEDB.el9.x86_64.rpm
pg_analytics_160.3.7el9.aarch64pigsty10.2 MiBpg_analytics_16-0.3.7-1PARADEDB.el9.aarch64.rpm
postgresql-16-pg-analytics0.3.7d12.x86_64pigsty10.2 MiBpostgresql-16-pg-analytics_0.3.7_amd64.deb
postgresql-16-pg-analytics0.3.7d12.aarch64pigsty8.8 MiBpostgresql-16-pg-analytics_0.3.7_arm64.deb
postgresql-16-pg-analytics0.3.7u22.x86_64pigsty10.3 MiBpostgresql-16-pg-analytics_0.3.7_amd64.deb
postgresql-16-pg-analytics0.3.7u22.aarch64pigsty9.0 MiBpostgresql-16-pg-analytics_0.3.7_arm64.deb
postgresql-16-pg-analytics0.3.7u24.x86_64pigsty10.6 MiBpostgresql-16-pg-analytics_0.3.7_amd64.deb
postgresql-16-pg-analytics0.3.7u24.aarch64pigsty9.2 MiBpostgresql-16-pg-analytics_0.3.7_arm64.deb
PackageVersionOSORGSIZEFile URL
pg_analytics_150.3.7el8.x86_64pigsty11.1 MiBpg_analytics_15-0.3.7-1PARADEDB.el8.x86_64.rpm
pg_analytics_150.3.7el8.aarch64pigsty9.7 MiBpg_analytics_15-0.3.7-1PARADEDB.el8.aarch64.rpm
pg_analytics_150.3.7el9.x86_64pigsty11.1 MiBpg_analytics_15-0.3.7-1PARADEDB.el9.x86_64.rpm
pg_analytics_150.3.7el9.aarch64pigsty10.2 MiBpg_analytics_15-0.3.7-1PARADEDB.el9.aarch64.rpm
postgresql-15-pg-analytics0.3.7d12.x86_64pigsty10.2 MiBpostgresql-15-pg-analytics_0.3.7_amd64.deb
postgresql-15-pg-analytics0.3.7d12.aarch64pigsty8.8 MiBpostgresql-15-pg-analytics_0.3.7_arm64.deb
postgresql-15-pg-analytics0.3.7u22.x86_64pigsty10.4 MiBpostgresql-15-pg-analytics_0.3.7_amd64.deb
postgresql-15-pg-analytics0.3.7u22.aarch64pigsty9.0 MiBpostgresql-15-pg-analytics_0.3.7_arm64.deb
postgresql-15-pg-analytics0.3.7u24.x86_64pigsty10.5 MiBpostgresql-15-pg-analytics_0.3.7_amd64.deb
postgresql-15-pg-analytics0.3.7u24.aarch64pigsty9.2 MiBpostgresql-15-pg-analytics_0.3.7_arm64.deb
PackageVersionOSORGSIZEFile URL
pg_analytics_140.3.7el8.x86_64pigsty11.1 MiBpg_analytics_14-0.3.7-1PARADEDB.el8.x86_64.rpm
pg_analytics_140.3.7el8.aarch64pigsty9.7 MiBpg_analytics_14-0.3.7-1PARADEDB.el8.aarch64.rpm
pg_analytics_140.3.7el9.x86_64pigsty11.1 MiBpg_analytics_14-0.3.7-1PARADEDB.el9.x86_64.rpm
pg_analytics_140.3.7el9.aarch64pigsty10.2 MiBpg_analytics_14-0.3.7-1PARADEDB.el9.aarch64.rpm
postgresql-14-pg-analytics0.3.7d12.x86_64pigsty10.2 MiBpostgresql-14-pg-analytics_0.3.7_amd64.deb
postgresql-14-pg-analytics0.3.7d12.aarch64pigsty8.8 MiBpostgresql-14-pg-analytics_0.3.7_arm64.deb
postgresql-14-pg-analytics0.3.7u22.x86_64pigsty10.3 MiBpostgresql-14-pg-analytics_0.3.7_amd64.deb
postgresql-14-pg-analytics0.3.7u22.aarch64pigsty9.0 MiBpostgresql-14-pg-analytics_0.3.7_arm64.deb
postgresql-14-pg-analytics0.3.7u24.x86_64pigsty10.6 MiBpostgresql-14-pg-analytics_0.3.7_amd64.deb
postgresql-14-pg-analytics0.3.7u24.aarch64pigsty9.1 MiBpostgresql-14-pg-analytics_0.3.7_arm64.deb
PackageVersionOSORGSIZEFile URL
pg_analytics_130.2.1el8.x86_64pigsty10.1 MiBpg_analytics_13-0.2.1-1PARADEDB.el8.x86_64.rpm
pg_analytics_130.2.1el8.aarch64pigsty8.8 MiBpg_analytics_13-0.2.1-1PARADEDB.el8.aarch64.rpm
pg_analytics_130.2.1el9.x86_64pigsty10.1 MiBpg_analytics_13-0.2.1-1PARADEDB.el9.x86_64.rpm
pg_analytics_130.2.1el9.aarch64pigsty9.3 MiBpg_analytics_13-0.2.1-1PARADEDB.el9.aarch64.rpm

Source

Install

To add the required PGDG / PIGSTY upstream repository, use:

pig repo add pgsql -u   # add PGDG + Pigsty repo and update cache (leave existing repos)

Install this extension with:

pig ext install pg_analytics; # install by extension name, for the current active PG version
pig ext install pg_analytics; # install via package alias, for the active PG version
pig ext install pg_analytics -v 17;   # install for PG 17
pig ext install pg_analytics -v 16;   # install for PG 16
pig ext install pg_analytics -v 15;   # install for PG 15
pig ext install pg_analytics -v 14;   # install for PG 14

Create this extension with:

CREATE EXTENSION pg_analytics CASCADE SCHEMA paradedb;

Usage

This extension is archived and no longer maintained. It is recommended to use other duckdb related extensions instead.

https://github.com/paradedb/pg_analytics

Example, read parquet files from S3:

CREATE EXTENSION pg_lakehouse;
CREATE FOREIGN DATA WRAPPER parquet_wrapper HANDLER parquet_fdw_handler VALIDATOR parquet_fdw_validator;

-- Provide S3 credentials
CREATE SERVER parquet_server FOREIGN DATA WRAPPER parquet_wrapper;

-- Create foreign table with auto schema creation
CREATE FOREIGN TABLE trips ()
SERVER parquet_server
OPTIONS (files 's3://paradedb-benchmarks/yellow_tripdata_2024-01.parquet');

-- Success! Now you can query the remote Parquet file like a regular Postgres table
SELECT COUNT(*) FROM trips;
  count
---------
 2964624
(1 row)

This fdw is read-only for now.


Iceberg Support

CREATE EXTENSION pg_lakehouse;

CREATE FOREIGN DATA WRAPPER iceberg_wrapper
    HANDLER iceberg_fdw_handler
    VALIDATOR iceberg_fdw_validator;

CREATE SERVER iceberg_server
    FOREIGN DATA WRAPPER iceberg_wrapper;

-- Replace the dummy schema with the actual schema
CREATE FOREIGN TABLE iceberg_table (x INT)
    SERVER iceberg_server
    OPTIONS (files 's3://bucket/iceberg_folder');

-- Success! You can now query the Iceberg table
SELECT COUNT(*) FROM iceberg_table;
Last updated on