Thread: BUG #3594: Error while compilation --`PQexecParams' undeclared (first use this function)

The following bug has been logged online:

Bug reference:      3594
Logged by:          Anil
Email address:      anil_gw@yahoo.com
PostgreSQL version: 8.2.4
Operating system:   Linux -- Kernel Version vmlinux-2.4.20-8
Description:        Error while compilation --`PQexecParams' undeclared
(first use this function)
Details:

Hi

I am trying to insert data to the table using PQexecParams API, but find
errors as

`PQexecParams' undeclared (first use this function) while compilation of the
source code.

Above is unexpected errors, since all others Postgres API complies and work
correctly. I verified the input arguments passed/ include path for libray/
header files, and have tried all possbile cases to rectify this error but
coulnd't do so.

Kindly help if there any problem with this library of PostGres version as
mentioned above. Or, which version of library, should I make use for
development work.

Waiting for your response asap

Thanks and regds
Anil

Re: BUG #3594: Error while compilation --`PQexecParams' undeclared (first use this function)

From
"Heikki Linnakangas"
Date:
Anil wrote:
> I am trying to insert data to the table using PQexecParams API, but find
> errors as
>
> `PQexecParams' undeclared (first use this function) while compilation of the
> source code.
>
> Above is unexpected errors, since all others Postgres API complies and work
> correctly. I verified the input arguments passed/ include path for libray/
> header files, and have tried all possbile cases to rectify this error but
> coulnd't do so.

PQexecParams was introduced in version 7.4. I noted that you're running
a 2.4 era kernel, so it's quite possible that your Linux distribution
came with PostgreSQL 7.3 and installed the header files in
/usr/src/include. Make sure the new header files come first in the
include path, or remove the old version altogether.

--
  Heikki Linnakangas
  EnterpriseDB   http://www.enterprisedb.com