[Lazarus] Fwd: Re: Trouble with PostGres access

Alex du Plessis alexdup01 at telkomsa.net
Sat Mar 21 17:40:26 CET 2009


Try copying all the dll's in the postgres bin directory to 
C:\WINDOWS\system32
 I have just created a test app with only TPQConnection filled in server 
name, database name, user and password and it connected without any 
hiccup. 

The messages you get are typically when Lazarus(and your app) can't see 
the dll's.

I also noticed that you are not running the postgres server locally 
(i.e. localhost - 127.0.0.1).  Have you edited postgres.conf on the 
server to allow connections from machines other than localhost? Stated 
differently: Have you told the postgres server to allow connections from 
network machines?

ArĂ­ Ricardo Ody wrote:
> Sat, 21 Mar 2009 08:00:19 +0200, Alex du Plessis <alexdup01 at telkomsa.net> escreveu:
>   
>> I am running a Postgres 8.3 db and I find no problems to connect,query 
>> and post to it.  However, I copied all the DLL's from the postgres bin 
>> directory(i.e. C:\Program Files\PostgreSQL\8.3\bin) into my application 
>> directory i.e. where the exe file resides.  I also distribute these 
>> files in the exe directory when I deploy the application.
>> I think the other directory to install them would be C:\WINDOWS\system32
>>     
>
> I can guarantee that I copy the dll's from the directory you tell above. Late, someone told about the dll's that reside in the pgAdmin directories and I copy again from there... 
>
> As soon as I read your message I copied all dll's from the same directory you mention in your message. When I try to change the "connected" property of TPQConnection to true, the errors remain appearing.
> (In the property DataBaseName of the TPQConnection I put the name of database that I saw via pgAdmin. Is this right?)
>
> Reading your message I can't have idea about what's the trouble in my environment and 'bout which other trials I should do.
>
> Thanks
>
> Ricardo
>
>
> _______________________________________________
> Lazarus mailing list
> Lazarus at lazarus.freepascal.org
> http://www.lazarus.freepascal.org/mailman/listinfo/lazarus
>
>   






More information about the Lazarus mailing list