|
@@ -222,6 +222,7 @@ type
|
|
|
procedure ApplyRecUpdate(Query : TCustomSQLQuery; UpdateKind : TUpdateKind); virtual;
|
|
|
function RefreshLastInsertID(Query : TCustomSQLQuery; Field : TField): Boolean; virtual;
|
|
|
procedure GetDBInfo(const ASchemaType : TSchemaType; const ASchemaObjectName, AReturnField : string; AList: TStrings);
|
|
|
+ function PortParamName: string; virtual;
|
|
|
function GetConnectionCharSet: string; virtual;
|
|
|
procedure SetTransaction(Value : TSQLTransaction); virtual;
|
|
|
procedure DoConnect; override;
|
|
@@ -1519,7 +1520,7 @@ end;
|
|
|
|
|
|
function TSQLConnection.GetPort: cardinal;
|
|
|
begin
|
|
|
- result := StrToIntDef(Params.Values['Port'],0);
|
|
|
+ result := StrToIntDef(Params.Values[PortParamName],0);
|
|
|
end;
|
|
|
|
|
|
procedure TSQLConnection.SetOptions(AValue: TSQLConnectionOptions);
|
|
@@ -1532,9 +1533,9 @@ end;
|
|
|
procedure TSQLConnection.SetPort(const AValue: cardinal);
|
|
|
begin
|
|
|
if AValue<>0 then
|
|
|
- Params.Values['Port']:=IntToStr(AValue)
|
|
|
- else with params do if IndexOfName('Port') > -1 then
|
|
|
- Delete(IndexOfName('Port'));
|
|
|
+ Params.Values[PortParamName]:=IntToStr(AValue)
|
|
|
+ else with params do if IndexOfName(PortParamName) > -1 then
|
|
|
+ Delete(IndexOfName(PortParamName));
|
|
|
end;
|
|
|
|
|
|
function TSQLConnection.AttemptCommit(trans: TSQLHandle): boolean;
|
|
@@ -2317,6 +2318,11 @@ begin
|
|
|
end;
|
|
|
end;
|
|
|
|
|
|
+function TSQLConnection.PortParamName: string;
|
|
|
+begin
|
|
|
+ Result := 'Port';
|
|
|
+end;
|
|
|
+
|
|
|
procedure TSQLConnection.CreateDB;
|
|
|
|
|
|
begin
|