Browse Source

* Call GetDBDialect in DoConnect since in DoInternalConnect Connected is false, so GetDBDialect effectively does nothing

git-svn-id: trunk@8940 -
joost 18 years ago
parent
commit
ab904addff
1 changed files with 7 additions and 1 deletions
  1. 7 1
      packages/fcl-db/src/sqldb/interbase/ibconnection.pp

+ 7 - 1
packages/fcl-db/src/sqldb/interbase/ibconnection.pp

@@ -69,6 +69,7 @@ type
     procedure FreeSQLDABuffer(var aSQLDA : PXSQLDA);
     procedure FreeSQLDABuffer(var aSQLDA : PXSQLDA);
     function  IsDialectStored: boolean;
     function  IsDialectStored: boolean;
   protected
   protected
+    procedure DoConnect; override;
     procedure DoInternalConnect; override;
     procedure DoInternalConnect; override;
     procedure DoInternalDisconnect; override;
     procedure DoInternalDisconnect; override;
     function GetHandle : pointer; override;
     function GetHandle : pointer; override;
@@ -389,7 +390,6 @@ begin
     @FSQLDatabaseHandle,
     @FSQLDatabaseHandle,
          Length(DPB), @DPB[1]) <> 0 then
          Length(DPB), @DPB[1]) <> 0 then
     CheckError('DoInternalConnect', FStatus);
     CheckError('DoInternalConnect', FStatus);
-  FDbDialect := GetDBDialect;
 end;
 end;
 
 
 function TIBConnection.GetDialect: integer;
 function TIBConnection.GetDialect: integer;
@@ -609,6 +609,12 @@ begin
   result := (FDialect<>-1);
   result := (FDialect<>-1);
 end;
 end;
 
 
+procedure TIBConnection.DoConnect;
+begin
+  inherited DoConnect;
+  FDbDialect := GetDBDialect;
+end;
+
 procedure TIBConnection.FreeFldBuffers(cursor : TSQLCursor);
 procedure TIBConnection.FreeFldBuffers(cursor : TSQLCursor);
 
 
 begin
 begin