Re: PostgreSQL function can not load dll library.

From: Craig Ringer <craig(at)postnewspapers(dot)com(dot)au>
To: A(dot)Bhattacharya(at)sungard(dot)com
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: PostgreSQL function can not load dll library.
Date: 2009-10-27 06:30:46
Message-ID: 1256625046.1709.86.camel@wallace.localnet
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Tue, 2009-10-27 at 02:19 -0400, A(dot)Bhattacharya(at)sungard(dot)com wrote:

> I am creating a dll using MSVC 2005 and trying to call the dll from my
> Postgres function

OK, so you're creating a PostgreSQL module implementing one or more
SQL-callable functions in C. When you load it into the server with
`CREATE FUNCTION' ?

> but unfortunately PostgreSQL is throwing an error message saying:
>
>
>
> ERROR: could not load library "C:/Program
> Files/PostgreSQL/8.3/lib/watchlist.dll": The specified module could
> not be found.

Assuming that the file is, in fact, on the path you've specified: Is it
possible that your DLL links to other DLLs that are not on the
PostgreSQL server's path? If your DLL links to another that cannot be
found, that error message is the one you'll get.

Dependency walker (depends.exe) from http://dependencywalker.com/ may
help you track that down.

--
Craig Ringer

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Raimon Fernandez 2009-10-27 07:20:21 Re: Implementing Frontend/Backend Protocol TCP/IP
Previous Message A.Bhattacharya 2009-10-27 06:19:30 PostgreSQL function can not load dll library.