Page 1 of 1

Problem with Dbx Postgresql Driver

Posted: Wed 09 Dec 2009 12:38
by marcosfraga
Hello,

I´m beggining to work with Dbx PostgreSQL Driver and i made an example application, in this application i have an SQLConnection with this parameters:

BlobSize=-1
HostName=localhost
DataBase=gweb
DriverName=DevartPostgreSQL
User_Name=postgres
Password=123456
FetchAll=false

When i try to open the SQLConnection in the Delphi2009 IDE an error happens:
"exception message : Socket error on connect. WSAGetLastError return"

Somebody can help me?

Thanks

Marcos

Posted: Mon 07 Mar 2011 13:04
by v14n7
i have the some problem, but i use RAD studio XE

n don't know what to do!

Posted: Wed 09 Mar 2011 13:57
by AlexP
Hello,

Please try to execute the following code:

Code: Select all

var 
SQLConnection: TSQLConnection; 
begin 
SQLConnection := TSQLConnection.Create(nil); 
SQLConnection.DriverName :='DevartPostgreSQL'; 
SQLConnection.ConnectionName :='Devart PostgreSQL'; 
SQLConnection.GetDriverFunc := 'getSQLDriverPostgreSQL'; 
SQLConnection.LibraryName := 'dbexppgsql40.dll'; 
SQLConnection.LoginPrompt := False; 
SQLConnection.Params.Values['HostName'] := 'host:port'; 
SQLConnection.Params.Values['Database'] := database'; 
SQLConnection.Params.Values['SchemaName'] := 'schema'; 
SQLConnection.Params.Values['User_Name'] := 'user'; 
SQLConnection.Params.Values['Password'] := 'passwd'; 
try 
SQLConnection.Connected := true; 
ShowMessage('OK'); 
except 
on E:Exception do 
ShowMessage(e.Message); 
end;
if the error persists, please specify the following information:
- the exact version of dbExpress driver for PostgreSQL;
- the exact version of PostgreSQL.