Code: Select all
Conn.Execute('SELECT cast(version() AS varchar(255))', Nil, @TempDataSet);
!!!Assertion failure (D:\Projects\Delphi\Dac\PostgreSql\Source\PgSQLProtocol.pas, line 2254)
Delphi 2007
Driver Version 1.40.0.13
Code: Select all
Conn.Execute('SELECT cast(version() AS varchar(255))', Nil, @TempDataSet);
!!!Assertion failure (D:\Projects\Delphi\Dac\PostgreSql\Source\PgSQLProtocol.pas, line 2254)
Code: Select all
var
SQLConnection: TSqlConnection;
TempDataSet: TDataSet;
begin
SQLConnection:= TSqlConnection.Create(nil);
SQLConnection.DriverName := 'DevartPostgreSQL';
SQLConnection.GetDriverFunc := 'getSQLDriverPostgreSQL';
SQLConnection.ConnectionName := 'Devart PostgreSQL';
SQLConnection.LibraryName:= 'dbexppgsql40.dll';
SQLConnection.VendorLib := 'dbexppgsql40.dll';
SQLConnection.LoginPrompt := false;
SQLConnection.Params.Values['hostname'] := 'postgres:5432';
SQLConnection.Params.Values['Database'] := 'postgres';
SQLConnection.Params.Values['User_Name'] := 'postgres';
SQLConnection.Params.Values['Password'] := 'postgres';
SQLConnection.Open;
SQLConnection.Execute('SELECT cast(version() AS varchar(255)) as ver', Nil, @TempDataSet);
ShowMessage(TempDataSet.fieldByName('ver').AsString);