My Experiences with Databases & More

Oracle-MySQL-SQL SERVER-Python-Azure-AWS-Oracle Cloud-GCP etc

  • Enter your email address to follow this blog and receive notifications of new posts by email.

  • Total Views

    • 558,511 hits
  • $riram $anka

    The experiences, Test cases, views, and opinions etc expressed in this website are my own and does not reflect the views or opinions of my employer. This site is independent of and does not represent Oracle Corporation in any way. Oracle does not officially sponsor, approve, or endorse this site or its content.Product and company names mentioned in this website may be the trademarks of their respective owners.

Script To Generate Alter Statements to Kill Locked Sessions in RDS

Posted by Sriram Sanka on May 28, 2021

Script to generate Kill Locked Sessions in Oracle :

In case of RDS ,

SELECT 'exec rdsadmin.rdsadmin_util.kill('||s.sid ||','|| s.serial# ||' );'
FROM v$session s ,
v$process p ,
v$lock l ,
dba_objects o
s.paddr = p.addr
AND l.sid = s.sid
AND l.id1 = o.object_id
AND s.username = 'XXAPPS' --- Change as needed.
AND object_name like ('XXSC%'); --- Change as needed.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.

%d bloggers like this: