Examples of using PQexecParams

Поиск
Список
Период
Сортировка
От Daniel
Тема Examples of using PQexecParams
Дата
Msg-id 6b07394f-ae70-4a96-8abf-fc615a09640d@a21g2000yqc.googlegroups.com
обсуждение исходный текст
Ответы Re: Examples of using PQexecParams  (John R Pierce <pierce@hogranch.com>)
Re: Examples of using PQexecParams  (Merlin Moncure <mmoncure@gmail.com>)
Список pgsql-general
I was looking for examples of using PQexecParams but all I found was
this: http://sepp.oetiker.ch/postgresql-8.2.3-ds/libpq-example.html

/* Convert integer value "2" to network byte order */
    binaryIntVal = htonl((uint32_t) 2);
/* Set up parameter arrays for PQexecParams */
    paramValues[0] = (char *) &binaryIntVal;
    paramLengths[0] = sizeof(binaryIntVal);
    paramFormats[0] = 1;        /* binary */
...
seems a bit convoluted.

In particular I was looking for an example of setting up a string
parameter for PQexecParams, assuming that is possible.

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

Предыдущее
От: Sam Mason
Дата:
Сообщение: Re: Array comparison & prefix search
Следующее
От: Kern Sibbald
Дата:
Сообщение: Re: Catastrophic changes to PostgreSQL 8.4