Re: PHP and Postgres arrays

Поиск
Список
Период
Сортировка
Искать
От
brian
Тема
Re: PHP and Postgres arrays
Дата
Msg-id
47914125.3010704@zijn-digital.com
Ответ на
Список
Дерево обсуждения
PHP and Postgres arrays Yannick Warnier <ywarnier@beeznest.org>
Re: PHP and Postgres arrays Ivan Sergio Borgonovo <mail@webthatworks.it>
Re: PHP and Postgres arrays Yannick Warnier <ywarnier@beeznest.org>
Re: PHP and Postgres arrays Hannes Dorbath <light@theendofthetunnel.de>
Re: PHP and Postgres arrays brian <brian@zijn-digital.com>
Hannes Dorbath wrote:
> Yannick Warnier wrote:
>> I thought about it, but it's not very portable if you want to ship a PHP
>> application. But I admit I will fall back to that solution if I cannot
>> find any other (considering PostgreSQL might be the only open-source
>> database to offer in-fields arrays anyway).
> 
> You can use the build in function array_to_string:
> http://www.postgresql.org/docs/8.3/static/functions-array.html
> 

Then use implode(YOUR_DELIMITER, YOUR_STRING) to get an array.

Another solution would be to use the MDB2 (or similar) PEAR wrapper.

b
В списке pgsql-general по дате отправления
От: Hannes Dorbath
Дата:
Сообщение: Re: PHP and Postgres arrays
От: Tom Lane
Дата:
FAQ