1on / hstore-extension

The encoder/decoder and set of the doctrine functions for the postgresql type `hstore`

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

HStore Extension

Build Status

PostgreSQL module hstore allows to store sets of key/value pairs within a single PostgreSQL value. More about it here.

The HStore Extension contains DBAL type hstore and registers Doctrine type hstore.

Installation

To install this library, run the command below and you will get the latest version:

composer require intaro/hstore-extension

If you want to run the tests:

./vendor/bin/phpunit

You can find an example configuration for using HStore extension in Symfony2 in config/hstore.yml. You can just include in you config.yml:

imports:
    - { resource: ../../vendor/intaro/hstore-extension/config/hstore.yml }

PHP extension

To speed up encoding/decoding of strings you can install C extension shipped in ext directory. Use appropriate folder for you php version hstore5x for 5.x and hstore7x for 7.x.

To compile extension you must install php-dev package.

phpize
./configure
make
sudo make install

Finally, enable the extension in your php.ini configuration file:

extension = hstore.so

About

The encoder/decoder and set of the doctrine functions for the postgresql type `hstore`

License:MIT License


Languages

Language:PHP 49.7%Language:C 48.9%Language:M4 0.8%Language:JavaScript 0.6%