Re: inserting bytea using PHPs pg_escape_bytea()

Поиск
Список
Период
Сортировка
От Martín Marqués
Тема Re: inserting bytea using PHPs pg_escape_bytea()
Дата
Msg-id CABeG9LtZ+4QvYDX17=AwEL3sonhtXWu6ARZTWp++xOBHXvWBGw@mail.gmail.com
обсуждение исходный текст
Ответ на Re: inserting bytea using PHPs pg_escape_bytea()  (Rodrigo Gonzalez <rjgonzale@estrads.com.ar>)
Список pgsql-general
El día 20 de octubre de 2011 14:28, Rodrigo Gonzalez
<rjgonzale@estrads.com.ar> escribió:
> El 20/10/11 14:13, Martín Marqués escribió:
>
> El día 19 de octubre de 2011 23:20, Jeff Davis <pgsql@j-davis.com> escribió:
>
> On Wed, 2011-10-19 at 14:30 -0300, Martín Marqués wrote:
>
> The only concern I have is that on insertion, I get this WARNING:
>
> WARNING:  nonstandard use of \\ in a string literal at character 41
> HINT:  Use the escape string syntax for backslashes, e.g., E'\\'.
>
> Should I worry? What does it mean?
>
> First of all, the best solution is to use parameterized queries:
>
> http://us.php.net/manual/en/function.pg-query-params.php
>
> How would that work with abstraction layers like MDB2 or PDO?
>
> With PDO just check http://www.php.net/manual/en/pdo.prepare.php

AFAIK, that's not the same as pg_query_params.

Thats more like pg_prepare() + pg_execute().

I use it a lot with MDB2, but couldn't find something like pg_query_params()

--
Martín Marqués
select 'martin.marques' || '@' || 'gmail.com'
DBA, Programador, Administrador

В списке pgsql-general по дате отправления:

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: Postgresql - FDW, ForeignScanState and subqueries
Следующее
От: Jeff Davis
Дата:
Сообщение: Re: inserting bytea using PHPs pg_escape_bytea()