PHPackages                             camelot/doctrine-postgres-bundle - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Database &amp; ORM](/categories/database)
4. /
5. camelot/doctrine-postgres-bundle

ActiveSymfony-bundle[Database &amp; ORM](/categories/database)

camelot/doctrine-postgres-bundle
================================

PostgreSQL specific functionality for Pentangle

v2.2.0(3y ago)210.4k↓18.2%1[1 issues](https://github.com/CamelotProject/doctrine-postgres-bundle/issues)MITPHPPHP ^7.4 || ^8.0

Since Oct 7Pushed 2y ago1 watchersCompare

[ Source](https://github.com/CamelotProject/doctrine-postgres-bundle)[ Packagist](https://packagist.org/packages/camelot/doctrine-postgres-bundle)[ RSS](/packages/camelot-doctrine-postgres-bundle/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (1)Dependencies (14)Versions (9)Used By (0)

Doctrine Postgres Bundle
========================

[](#doctrine-postgres-bundle)

**NOTE:** For legacy PHP support (7.2+) please use the 1.0 branch.

This bundle provides Doctrine support for some specific PostgreSQL 9.4+ features for Symfony projects:

- Support of JSONB and some array data-types (at present only integers, TEXT and JSONB)
- Implementation of the most commonly used functions and operators when working with array and JSON data-types Functions for text search

Libraries used:

- [martin-georgiev/postgresql-for-doctrine](https://github.com/martin-georgiev/postgresql-for-doctrine)

Installation
------------

[](#installation)

### Applications that use Symfony Flex

[](#applications-that-use-symfony-flex)

Open a command console, enter your project directory and execute:

```
composer require camelot/doctrine-postgres-bundle
```

### Applications that don't use Symfony Flex

[](#applications-that-dont-use-symfony-flex)

#### Step 1: Download the Bundle

[](#step-1-download-the-bundle)

Open a command console, enter your project directory and execute the following command to download the latest stable version of this bundle:

```
composer require camelot/doctrine-postgres-bundle
```

This command requires you to have Composer installed globally, as explained in the [installation chapter](https://getcomposer.org/doc/00-intro.md)of the Composer documentation.

#### Step 2: Enable the Bundle

[](#step-2-enable-the-bundle)

Then, enable the bundle by adding it to the list of registered bundles in the `config/bundles.php` file of your project:

```
// config/bundles.php

return [
    // ...
    Camelot\DoctrinePostgres\CamelotDoctrinePostgresBundle::class => ['all' => true],
];
```

Using
-----

[](#using)

### Available DBAL Types

[](#available-dbal-types)

- `jsonb`
- `jsonb[]`
- `smallint[]`
- `integer[]`
- `bigint[]`
- `text[]`

### Available String Functions

[](#available-string-functions)

- `ALL_OF`
- `ANY_OF`
- `ARRAY_APPEND`
- `ARRAY_CARDINALITY`
- `ARRAY_CAT`
- `ARRAY_DIMENSIONS`
- `ARRAY_LENGTH`
- `ARRAY_NUMBER_OF_DIMENSIONS`
- `ARRAY_PREPEND`
- `ARRAY_REMOVE`
- `ARRAY_REPLACE`
- `ARRAY_TO_JSON`
- `ARRAY_TO_STRING`
- `CAST()`
- `CONTAINS`
- `DATE_PART()`
- `GREATEST`
- `ILIKE`
- `IN_ARRAY`
- `IS_CONTAINED_BY`
- `JSON_ARRAY_LENGTH`
- `JSONB_ARRAY_ELEMENTS`
- `JSONB_ARRAY_ELEMENTS_TEXT`
- `JSONB_ARRAY_LENGTH`
- `JSONB_EACH`
- `JSONB_EACH_TEXT`
- `JSONB_EXISTS`
- `JSONB_INSERT`
- `JSONB_OBJECT_KEYS`
- `JSONB_SET`
- `JSONB_STRIP_NULLS`
- `JSON_EACH`
- `JSON_EACH_TEXT`
- `JSON_GET_FIELD`
- `JSON_GET_FIELD_AS_INTEGER`
- `JSON_GET_FIELD_AS_TEXT`
- `JSON_GET_OBJECT`
- `JSON_GET_OBJECT_AS_TEXT`
- `JSON_OBJECT_KEYS`
- `JSON_STRIP_NULLS`
- `LEAST`
- `MAKE_DATE()`
- `OVERLAPS`
- `STRING_TO_ARRAY`
- `TO_CHAR()`
- `TO_JSON`
- `TO_JSONB`
- `TO_TSQUERY`
- `TO_TSVECTOR`
- `TSMATCH`

See [Common errors when using ILIKE, CONTAINS, IS\_CONTAINED\_BY and other operator-like functions](https://github.com/martin-georgiev/postgresql-for-doctrine/blob/master/docs/USE-CASES-AND-EXAMPLES.md)for tip(s) on using the functions.

###  Health Score

33

—

LowBetter than 75% of packages

Maintenance10

Infrequent updates — may be unmaintained

Popularity28

Limited adoption so far

Community11

Small or concentrated contributor base

Maturity68

Established project with proven stability

 Bus Factor1

Top contributor holds 88.9% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~218 days

Recently: every ~319 days

Total

7

Last Release

1103d ago

Major Versions

v1.0.0 → v2.0.02019-10-07

v1.0.1 → v2.0.12019-11-13

1.0.x-dev → v2.1.02022-01-04

PHP version history (3 changes)v1.0.0PHP ^7.2

v2.0.0PHP ^7.4

v2.1.0PHP ^7.4 || ^8.0

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/22109404?v=4)[gwendolen](/maintainers/gwendolen)[@gwendolen](https://github.com/gwendolen)

---

Top Contributors

[![GwendolenLynch](https://avatars.githubusercontent.com/u/1427081?v=4)](https://github.com/GwendolenLynch "GwendolenLynch (24 commits)")[![tacman](https://avatars.githubusercontent.com/u/619585?v=4)](https://github.com/tacman "tacman (2 commits)")[![FluffyDiscord](https://avatars.githubusercontent.com/u/10332247?v=4)](https://github.com/FluffyDiscord "FluffyDiscord (1 commits)")

---

Tags

doctrinedoctrine-dbaldoctrine-ormsymfonysymfony-bundle

###  Code Quality

TestsPHPUnit

Static AnalysisPsalm

Code StylePHP CS Fixer

Type Coverage Yes

### Embed Badge

![Health badge](/badges/camelot-doctrine-postgres-bundle/health.svg)

```
[![Health](https://phpackages.com/badges/camelot-doctrine-postgres-bundle/health.svg)](https://phpackages.com/packages/camelot-doctrine-postgres-bundle)
```

###  Alternatives

[scienta/doctrine-json-functions

A set of extensions to Doctrine that add support for json query functions.

58523.9M36](/packages/scienta-doctrine-json-functions)[laravel-doctrine/orm

An integration library for Laravel and Doctrine ORM

8425.3M87](/packages/laravel-doctrine-orm)[damienharper/auditor-bundle

Integrate auditor library in your Symfony projects.

4542.8M](/packages/damienharper-auditor-bundle)[sonata-project/entity-audit-bundle

Audit for Doctrine Entities

644989.8k1](/packages/sonata-project-entity-audit-bundle)[bartlett/php-compatinfo-db

Reference Database of all functions, constants, classes, interfaces on PHP standard distribution and about 110 extensions

1183.0k1](/packages/bartlett-php-compatinfo-db)[heymoon/doctrine-psql-enum

Store PHP native enums as PostgeSQL custom enum types

254.9k](/packages/heymoon-doctrine-psql-enum)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
