PHPackages                             icicleio/postgres - 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. icicleio/postgres

ArchivedLibrary[Database &amp; ORM](/categories/database)

icicleio/postgres
=================

Asynchronous PostgreSQL client for Icicle.

v1.x-dev(10y ago)423MITPHP

Since May 9Pushed 10y ago2 watchersCompare

[ Source](https://github.com/icicleio/postgres)[ Packagist](https://packagist.org/packages/icicleio/postgres)[ Docs](http://icicle.io)[ RSS](/packages/icicleio-postgres/feed)WikiDiscussions master Synced 4w ago

READMEChangelogDependencies (2)Versions (3)Used By (0)

PostgreSQL Client for Icicle
============================

[](#postgresql-client-for-icicle)

This library is a component for [Icicle](https://github.com/icicleio/icicle) that provides an asynchronous client for PostgreSQL. Like other Icicle components, this library uses [Coroutines](https://icicle.io/docs/manual/coroutines/) built from [Awaitables](https://icicle.io/docs/manual/awaitables/) and [Generators](http://www.php.net/manual/en/language.generators.overview.php) to make writing asynchronous code more like writing synchronous code.

[![Build Status](https://camo.githubusercontent.com/57a0bcb63e82024bcd3d31ce6c61cd1da8ec70aee83a681e6ea58eabb1a1f3c0/68747470733a2f2f696d672e736869656c64732e696f2f7472617669732f696369636c65696f2f706f7374677265732f76312e782e7376673f7374796c653d666c61742d737175617265)](https://travis-ci.org/icicleio/postgres)[![Coverage Status](https://camo.githubusercontent.com/a4f19d32300b599b321dcea0445476a020f2b3522eb725614076dc46b82b13b7/68747470733a2f2f696d672e736869656c64732e696f2f636f766572616c6c732f696369636c65696f2f706f7374677265732f76312e782e7376673f7374796c653d666c61742d737175617265)](https://coveralls.io/r/icicleio/postgres)[![Semantic Version](https://camo.githubusercontent.com/bc4d3ce65f33b4d1472cd387aea05c506011fa2b3624422a490cd945236f691c/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f72656c656173652f696369636c65696f2f706f7374677265732e7376673f7374796c653d666c61742d737175617265)](http://semver.org)[![MIT License](https://camo.githubusercontent.com/24e4fa8048b9f4ed967f8980b455346ea4ad71f2fa15f9177442e4a44c0088e1/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f6c2f696369636c65696f2f706f7374677265732e7376673f7374796c653d666c61742d737175617265)](LICENSE)[![@icicleio on Twitter](https://camo.githubusercontent.com/fb16a2e03bb85dd9926a15e837d3754b7766046281e2698271930aadbcd972cf/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f747769747465722d253430696369636c65696f2d3531383963372e7376673f7374796c653d666c61742d737175617265)](https://twitter.com/icicleio)

#### Documentation and Support

[](#documentation-and-support)

- [Full API Documentation](https://icicle.io/docs)
- [Official Twitter](https://twitter.com/icicleio)
- [Gitter Chat](https://gitter.im/icicleio/icicle)

##### Requirements

[](#requirements)

- PHP 5.5+ for v0.1.x branch
- PHP 7 for v1.0 (v1.x branch and master) supporting generator delegation and return expressions

##### Installation

[](#installation)

The recommended way to install is with the [Composer](http://getcomposer.org/) package manager. (See the [Composer installation guide](https://getcomposer.org/doc/00-intro.md) for information on installing and using Composer.)

Run the following command to use this library in your project:

```
composer require icicleio/postgres
```

You can also manually edit `composer.json` to add this library as a project requirement.

```
// composer.json
{
    "require": {
        "icicleio/postgres": "^0.1"
    }
}
```

#### Example

[](#example)

Note that this example uses the PHP 7+ only v1.x (master) branch.

```
#!/usr/bin/env php
