Skip to content

pgqr

QR Code generator from PostgreSQL

pgqr : QR Code generator from PostgreSQL

Overview

ID Extension Package Version Category License Language
4260 pgqr pgqr 1.0 UTIL BSD-3-Clause C
Attribute Has Binary Has Library Need Load Has DDL Relocatable Trusted
--s-d-r No Yes No Yes yes no

Packages

Type Repo Version PG Major Compatibility Package Pattern Dependencies
EXT PIGSTY 1.0 19 18 17 16 15 pgqr -
RPM PIGSTY 1.0 19 18 17 16 15 pgqr_$v -
DEB PIGSTY 1.0 19 18 17 16 15 postgresql-$v-pgqr -
Linux / PG PG19 PG18 PG17 PG16 PG15
el8.x86_64 N/A PIGSTY 1.0 PIGSTY 1.0 PIGSTY 1.0 PIGSTY 1.0
el8.aarch64 N/A PIGSTY 1.0 PIGSTY 1.0 PIGSTY 1.0 PIGSTY 1.0
el9.x86_64 PIGSTY 1.0 PIGSTY 1.0 PIGSTY 1.0 PIGSTY 1.0 PIGSTY 1.0
el9.aarch64 PIGSTY 1.0 PIGSTY 1.0 PIGSTY 1.0 PIGSTY 1.0 PIGSTY 1.0
el10.x86_64 PIGSTY 1.0 PIGSTY 1.0 PIGSTY 1.0 PIGSTY 1.0 PIGSTY 1.0
el10.aarch64 PIGSTY 1.0 PIGSTY 1.0 PIGSTY 1.0 PIGSTY 1.0 PIGSTY 1.0
d12.x86_64 PIGSTY 1.0 PIGSTY 1.0 PIGSTY 1.0 PIGSTY 1.0 PIGSTY 1.0
d12.aarch64 PIGSTY 1.0 PIGSTY 1.0 PIGSTY 1.0 PIGSTY 1.0 PIGSTY 1.0
d13.x86_64 PIGSTY 1.0 PIGSTY 1.0 PIGSTY 1.0 PIGSTY 1.0 PIGSTY 1.0
d13.aarch64 PIGSTY 1.0 PIGSTY 1.0 PIGSTY 1.0 PIGSTY 1.0 PIGSTY 1.0
u22.x86_64 PIGSTY 1.0 PIGSTY 1.0 PIGSTY 1.0 PIGSTY 1.0 PIGSTY 1.0
u22.aarch64 PIGSTY 1.0 PIGSTY 1.0 PIGSTY 1.0 PIGSTY 1.0 PIGSTY 1.0
u24.x86_64 PIGSTY 1.0 PIGSTY 1.0 PIGSTY 1.0 PIGSTY 1.0 PIGSTY 1.0
u24.aarch64 PIGSTY 1.0 PIGSTY 1.0 PIGSTY 1.0 PIGSTY 1.0 PIGSTY 1.0
u26.x86_64 PIGSTY 1.0 PIGSTY 1.0 PIGSTY 1.0 PIGSTY 1.0 PIGSTY 1.0
u26.aarch64 PIGSTY 1.0 PIGSTY 1.0 PIGSTY 1.0 PIGSTY 1.0 PIGSTY 1.0
Package Version OS ORG SIZE File URL
pgqr_19 1.0 el9.x86_64 pigsty 56.5 KiB pgqr_19-1.0-1PGSTY.el9.x86_64.rpm
pgqr_19 1.0 el9.aarch64 pigsty 56.1 KiB pgqr_19-1.0-1PGSTY.el9.aarch64.rpm
pgqr_19 1.0 el10.x86_64 pigsty 57.5 KiB pgqr_19-1.0-1PGSTY.el10.x86_64.rpm
pgqr_19 1.0 el10.aarch64 pigsty 55.8 KiB pgqr_19-1.0-1PGSTY.el10.aarch64.rpm
postgresql-19-pgqr 1.0 d12.x86_64 pigsty 48.0 KiB postgresql-19-pgqr_1.0-1PGSTY~bookworm_amd64.deb
postgresql-19-pgqr 1.0 d12.aarch64 pigsty 46.7 KiB postgresql-19-pgqr_1.0-1PGSTY~bookworm_arm64.deb
postgresql-19-pgqr 1.0 d13.x86_64 pigsty 48.3 KiB postgresql-19-pgqr_1.0-1PGSTY~trixie_amd64.deb
postgresql-19-pgqr 1.0 d13.aarch64 pigsty 46.8 KiB postgresql-19-pgqr_1.0-1PGSTY~trixie_arm64.deb
postgresql-19-pgqr 1.0 u22.x86_64 pigsty 50.3 KiB postgresql-19-pgqr_1.0-1PGSTY~jammy_amd64.deb
postgresql-19-pgqr 1.0 u22.aarch64 pigsty 49.0 KiB postgresql-19-pgqr_1.0-1PGSTY~jammy_arm64.deb
postgresql-19-pgqr 1.0 u24.x86_64 pigsty 50.1 KiB postgresql-19-pgqr_1.0-1PGSTY~noble_amd64.deb
postgresql-19-pgqr 1.0 u24.aarch64 pigsty 49.1 KiB postgresql-19-pgqr_1.0-1PGSTY~noble_arm64.deb
postgresql-19-pgqr 1.0 u26.x86_64 pigsty 50.6 KiB postgresql-19-pgqr_1.0-1PGSTY~resolute_amd64.deb
postgresql-19-pgqr 1.0 u26.aarch64 pigsty 49.6 KiB postgresql-19-pgqr_1.0-1PGSTY~resolute_arm64.deb
Package Version OS ORG SIZE File URL
pgqr_18 1.0 el8.x86_64 pigsty 55.9 KiB pgqr_18-1.0-1PGSTY.el8.x86_64.rpm
pgqr_18 1.0 el8.aarch64 pigsty 55.1 KiB pgqr_18-1.0-1PGSTY.el8.aarch64.rpm
pgqr_18 1.0 el9.x86_64 pigsty 56.5 KiB pgqr_18-1.0-1PGSTY.el9.x86_64.rpm
pgqr_18 1.0 el9.aarch64 pigsty 56.1 KiB pgqr_18-1.0-1PGSTY.el9.aarch64.rpm
pgqr_18 1.0 el10.x86_64 pigsty 57.5 KiB pgqr_18-1.0-1PGSTY.el10.x86_64.rpm
pgqr_18 1.0 el10.aarch64 pigsty 55.8 KiB pgqr_18-1.0-1PGSTY.el10.aarch64.rpm
postgresql-18-pgqr 1.0 d12.x86_64 pigsty 47.9 KiB postgresql-18-pgqr_1.0-1PGSTY~bookworm_amd64.deb
postgresql-18-pgqr 1.0 d12.aarch64 pigsty 46.7 KiB postgresql-18-pgqr_1.0-1PGSTY~bookworm_arm64.deb
postgresql-18-pgqr 1.0 d13.x86_64 pigsty 48.3 KiB postgresql-18-pgqr_1.0-1PGSTY~trixie_amd64.deb
postgresql-18-pgqr 1.0 d13.aarch64 pigsty 46.8 KiB postgresql-18-pgqr_1.0-1PGSTY~trixie_arm64.deb
postgresql-18-pgqr 1.0 u22.x86_64 pigsty 50.3 KiB postgresql-18-pgqr_1.0-1PGSTY~jammy_amd64.deb
postgresql-18-pgqr 1.0 u22.aarch64 pigsty 48.9 KiB postgresql-18-pgqr_1.0-1PGSTY~jammy_arm64.deb
postgresql-18-pgqr 1.0 u24.x86_64 pigsty 50.1 KiB postgresql-18-pgqr_1.0-1PGSTY~noble_amd64.deb
postgresql-18-pgqr 1.0 u24.aarch64 pigsty 49.1 KiB postgresql-18-pgqr_1.0-1PGSTY~noble_arm64.deb
postgresql-18-pgqr 1.0 u26.x86_64 pigsty 50.6 KiB postgresql-18-pgqr_1.0-1PGSTY~resolute_amd64.deb
postgresql-18-pgqr 1.0 u26.aarch64 pigsty 49.6 KiB postgresql-18-pgqr_1.0-1PGSTY~resolute_arm64.deb
Package Version OS ORG SIZE File URL
pgqr_17 1.0 el8.x86_64 pigsty 55.9 KiB pgqr_17-1.0-1PGSTY.el8.x86_64.rpm
pgqr_17 1.0 el8.aarch64 pigsty 55.0 KiB pgqr_17-1.0-1PGSTY.el8.aarch64.rpm
pgqr_17 1.0 el9.x86_64 pigsty 56.5 KiB pgqr_17-1.0-1PGSTY.el9.x86_64.rpm
pgqr_17 1.0 el9.aarch64 pigsty 56.1 KiB pgqr_17-1.0-1PGSTY.el9.aarch64.rpm
pgqr_17 1.0 el10.x86_64 pigsty 57.5 KiB pgqr_17-1.0-1PGSTY.el10.x86_64.rpm
pgqr_17 1.0 el10.aarch64 pigsty 55.7 KiB pgqr_17-1.0-1PGSTY.el10.aarch64.rpm
postgresql-17-pgqr 1.0 d12.x86_64 pigsty 47.9 KiB postgresql-17-pgqr_1.0-1PGSTY~bookworm_amd64.deb
postgresql-17-pgqr 1.0 d12.aarch64 pigsty 46.6 KiB postgresql-17-pgqr_1.0-1PGSTY~bookworm_arm64.deb
postgresql-17-pgqr 1.0 d13.x86_64 pigsty 48.3 KiB postgresql-17-pgqr_1.0-1PGSTY~trixie_amd64.deb
postgresql-17-pgqr 1.0 d13.aarch64 pigsty 46.7 KiB postgresql-17-pgqr_1.0-1PGSTY~trixie_arm64.deb
postgresql-17-pgqr 1.0 u22.x86_64 pigsty 51.0 KiB postgresql-17-pgqr_1.0-1PGSTY~jammy_amd64.deb
postgresql-17-pgqr 1.0 u22.aarch64 pigsty 49.7 KiB postgresql-17-pgqr_1.0-1PGSTY~jammy_arm64.deb
postgresql-17-pgqr 1.0 u24.x86_64 pigsty 50.0 KiB postgresql-17-pgqr_1.0-1PGSTY~noble_amd64.deb
postgresql-17-pgqr 1.0 u24.aarch64 pigsty 49.1 KiB postgresql-17-pgqr_1.0-1PGSTY~noble_arm64.deb
postgresql-17-pgqr 1.0 u26.x86_64 pigsty 50.6 KiB postgresql-17-pgqr_1.0-1PGSTY~resolute_amd64.deb
postgresql-17-pgqr 1.0 u26.aarch64 pigsty 49.6 KiB postgresql-17-pgqr_1.0-1PGSTY~resolute_arm64.deb
Package Version OS ORG SIZE File URL
pgqr_16 1.0 el8.x86_64 pigsty 55.9 KiB pgqr_16-1.0-1PGSTY.el8.x86_64.rpm
pgqr_16 1.0 el8.aarch64 pigsty 55.0 KiB pgqr_16-1.0-1PGSTY.el8.aarch64.rpm
pgqr_16 1.0 el9.x86_64 pigsty 56.5 KiB pgqr_16-1.0-1PGSTY.el9.x86_64.rpm
pgqr_16 1.0 el9.aarch64 pigsty 56.1 KiB pgqr_16-1.0-1PGSTY.el9.aarch64.rpm
pgqr_16 1.0 el10.x86_64 pigsty 57.5 KiB pgqr_16-1.0-1PGSTY.el10.x86_64.rpm
pgqr_16 1.0 el10.aarch64 pigsty 55.7 KiB pgqr_16-1.0-1PGSTY.el10.aarch64.rpm
postgresql-16-pgqr 1.0 d12.x86_64 pigsty 47.9 KiB postgresql-16-pgqr_1.0-1PGSTY~bookworm_amd64.deb
postgresql-16-pgqr 1.0 d12.aarch64 pigsty 46.6 KiB postgresql-16-pgqr_1.0-1PGSTY~bookworm_arm64.deb
postgresql-16-pgqr 1.0 d13.x86_64 pigsty 48.3 KiB postgresql-16-pgqr_1.0-1PGSTY~trixie_amd64.deb
postgresql-16-pgqr 1.0 d13.aarch64 pigsty 46.8 KiB postgresql-16-pgqr_1.0-1PGSTY~trixie_arm64.deb
postgresql-16-pgqr 1.0 u22.x86_64 pigsty 51.0 KiB postgresql-16-pgqr_1.0-1PGSTY~jammy_amd64.deb
postgresql-16-pgqr 1.0 u22.aarch64 pigsty 49.7 KiB postgresql-16-pgqr_1.0-1PGSTY~jammy_arm64.deb
postgresql-16-pgqr 1.0 u24.x86_64 pigsty 50.0 KiB postgresql-16-pgqr_1.0-1PGSTY~noble_amd64.deb
postgresql-16-pgqr 1.0 u24.aarch64 pigsty 49.1 KiB postgresql-16-pgqr_1.0-1PGSTY~noble_arm64.deb
postgresql-16-pgqr 1.0 u26.x86_64 pigsty 50.5 KiB postgresql-16-pgqr_1.0-1PGSTY~resolute_amd64.deb
postgresql-16-pgqr 1.0 u26.aarch64 pigsty 49.6 KiB postgresql-16-pgqr_1.0-1PGSTY~resolute_arm64.deb
Package Version OS ORG SIZE File URL
pgqr_15 1.0 el8.x86_64 pigsty 56.3 KiB pgqr_15-1.0-1PGSTY.el8.x86_64.rpm
pgqr_15 1.0 el8.aarch64 pigsty 55.5 KiB pgqr_15-1.0-1PGSTY.el8.aarch64.rpm
pgqr_15 1.0 el9.x86_64 pigsty 57.3 KiB pgqr_15-1.0-1PGSTY.el9.x86_64.rpm
pgqr_15 1.0 el9.aarch64 pigsty 57.0 KiB pgqr_15-1.0-1PGSTY.el9.aarch64.rpm
pgqr_15 1.0 el10.x86_64 pigsty 58.5 KiB pgqr_15-1.0-1PGSTY.el10.x86_64.rpm
pgqr_15 1.0 el10.aarch64 pigsty 56.8 KiB pgqr_15-1.0-1PGSTY.el10.aarch64.rpm
postgresql-15-pgqr 1.0 d12.x86_64 pigsty 47.8 KiB postgresql-15-pgqr_1.0-1PGSTY~bookworm_amd64.deb
postgresql-15-pgqr 1.0 d12.aarch64 pigsty 46.6 KiB postgresql-15-pgqr_1.0-1PGSTY~bookworm_arm64.deb
postgresql-15-pgqr 1.0 d13.x86_64 pigsty 48.4 KiB postgresql-15-pgqr_1.0-1PGSTY~trixie_amd64.deb
postgresql-15-pgqr 1.0 d13.aarch64 pigsty 47.0 KiB postgresql-15-pgqr_1.0-1PGSTY~trixie_arm64.deb
postgresql-15-pgqr 1.0 u22.x86_64 pigsty 51.4 KiB postgresql-15-pgqr_1.0-1PGSTY~jammy_amd64.deb
postgresql-15-pgqr 1.0 u22.aarch64 pigsty 50.2 KiB postgresql-15-pgqr_1.0-1PGSTY~jammy_arm64.deb
postgresql-15-pgqr 1.0 u24.x86_64 pigsty 50.6 KiB postgresql-15-pgqr_1.0-1PGSTY~noble_amd64.deb
postgresql-15-pgqr 1.0 u24.aarch64 pigsty 49.6 KiB postgresql-15-pgqr_1.0-1PGSTY~noble_arm64.deb
postgresql-15-pgqr 1.0 u26.x86_64 pigsty 51.3 KiB postgresql-15-pgqr_1.0-1PGSTY~resolute_amd64.deb
postgresql-15-pgqr 1.0 u26.aarch64 pigsty 50.4 KiB postgresql-15-pgqr_1.0-1PGSTY~resolute_arm64.deb

Source

pig build pkg pgqr;		# build rpm/deb

Install

Make sure PGDG and PIGSTY repo available:

pig repo add pgsql -u   # add both repo and update cache

Install this extension with pig:

pig install pgqr;		# install via package name, for the active PG version

pig install pgqr -v 19;   # install for PG 19
pig install pgqr -v 18;   # install for PG 18
pig install pgqr -v 17;   # install for PG 17
pig install pgqr -v 16;   # install for PG 16
pig install pgqr -v 15;   # install for PG 15

Create this extension with:

CREATE EXTENSION pgqr;

Usage

pgqr: QR code generation for PostgreSQL

Function

pgqr(t text, correction_level integer, model_number integer, scale integer) RETURNS bytea

Parameters:

  • t – text to encode into the QR code
  • correction_level – error correction level: 0 to 3
  • model_number – QR model number: 0 to 2
  • scale – pixels per dot (scaling factor)

Example

Generate a QR code as a monochrome bitmap:

SELECT pgqr('QR Code with PostgreSQL', 0, 0, 4);

The output is a monochrome bitmap image (BMP format) returned as bytea, ready for display or storage.

Table reader