SQL Monitor shows the following:
Code: Select all
19 11:43:32 SQL Execute: begin :result := sys.dbms_transaction.local_transaction_id; end;
20 11:43:32 :result(VARCHAR[0])=<NULL>
21 11:43:32 Error: ORA-06502: PL/SQL: numeric or value error: character string buffer too small
ORA-06512: at line 1
Code: Select all
function GetTransactionID(ASession: TOraSession) : string;
begin
Result := '';
with ASession do
if Connected then
begin
ExecSQL('begin' +
' :Result := sys.dbms_transaction.local_transaction_id; ' +
'end;', []);
Result := ParamByName('Result').AsString;
end;
end;