Link to home
Start Free TrialLog in
Avatar of Raf
Raf

asked on

Session that filled up my transaction logs

Hi,
I've Sybase ASE 15.7 version.

Often I have a process that fill up my transaction logs, to see which process is responsible for filling up the logs I run this query:

select loginfo('<dbname>', 'database_has_active_transaction'),
    loginfo('<dbname>', 'oldest_active_transaction_pct'),
       loginfo('<dbname>', 'oldest_active_transaction_spid'),
       loginfo('<dbname>', 'can_free_using_dump_tran'),
       loginfo('<dbname>', 'is_stp_blocking_dump'),
       loginfo('<dbname>', 'stp_span_pct')
go

and after I kill the spid to free up space

kill <oldest_active_transaction_spid>
go

 
To details of the session I use "sp_who" procedure or this query:
select spid, status, hostprocess, program_name, clientname, loggedindatetime
from sysprocesses
go

But I'd like to get more details about the session that filled up my transaction logs, for example I'd like to know the exact SQL text that is being executed for "oldest_active_transaction_spid".

In addition is there a system table or history log file where the statements by a SPID are stored?

Thanks in advance!
ASKER CERTIFIED SOLUTION
Avatar of alpmoon
alpmoon
Flag of Australia image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial