87 |
|
function GetActivityIntf(att: IAttachment): IActivityMonitor; override; |
88 |
|
function GetTrInfo(ReqBuffer: PByte; ReqBufLen: integer): ITrInformation; override; |
89 |
|
procedure SetInterface(api: TFBClientAPI); override; |
90 |
+ |
procedure SetErrorHandler(Attachment: IAttachment); override; |
91 |
|
procedure InternalStartSingle(attachment: IAttachment); override; |
92 |
|
procedure InternalStartMultiple; override; |
93 |
|
function InternalCommit(Force: boolean): TTrCompletionState; override; |
119 |
|
begin |
120 |
|
Result := TTrInformation.Create(FFirebird25ClientAPI); |
121 |
|
with FFirebird25ClientAPI, Result as TTrInformation do |
122 |
+ |
begin |
123 |
|
if isc_transaction_info(StatusVector, @(FHandle), ReqBufLen, ReqBuffer, |
124 |
|
getBufSize, Buffer) > 0 then |
125 |
< |
IBDataBaseError; |
125 |
> |
raise EIBInterBaseError.Create(GetStatus,ConnectionCodePage); |
126 |
> |
end; |
127 |
|
end; |
128 |
|
|
129 |
|
procedure TFB25Transaction.SetInterface(api: TFBClientAPI); |
130 |
|
begin |
131 |
|
inherited SetInterface(api); |
132 |
|
FFirebird25ClientAPI := api as TFB25ClientAPI; |
133 |
< |
OnDatabaseError := FFirebird25ClientAPI.IBDataBaseError; |
133 |
> |
end; |
134 |
> |
|
135 |
> |
procedure TFB25Transaction.SetErrorHandler(Attachment: IAttachment); |
136 |
> |
begin |
137 |
> |
if Attachment <> nil then |
138 |
> |
OnDatabaseError := (Attachment as TFB25Attachment).IBDataBaseError; |
139 |
|
end; |
140 |
|
|
141 |
|
procedure TFB25Transaction.InternalStartSingle(attachment: IAttachment); |