Skip to content
pvmehta.com

pvmehta.com

  • Home
  • About Me
  • Toggle search form
  • Find execution plan from dba_hist_sql_plan for a specific SQL_ID and PLAN_HASH_VALUE fplan.sql Oracle
  • Reading config file from other folder inside class Python/PySpark
  • checking redhat linux version Linux/Unix
  • Privileges Required to Create Procedures and Functions that uses objects from other schema. Oracle
  • Jai Shree Ram Oracle
  • To see how much time or progress of long transaction Oracle
  • v$backup.status information Oracle
  • Getting started with notebook Python/PySpark
  • Recovering lost SYS password Oracle
  • How to remove blank lines using vi editor command Linux/Unix
  • .profile Linux/Unix
  • copying/removing directory with all its subdirectory Linux/Unix
  • create PLAN_TABLE command. Oracle
  • Giving Grant on v$DATABASE Oracle
  • chk_space_SID.ksh Linux/Unix

sid_wise_sql.sql

Posted on 30-Jan-2006 By Admin No Comments on sid_wise_sql.sql

accept u_name prompt ‘Enter User Name (Enter NONE if want SID specific query): ‘

accept s_id prompt ‘Enter SID (Enter 0 for Userspecific Query): ‘

select a.sid, b.sql_text, a.sql_id, c.spid, b.executions, b.disk_reads, b.elapsed_time, b.cpu_time, b.buffer_gets

from v$session a, v$sqlarea b, v$process c

where a.sql_id = b.sql_id(+)

and (a.username = upper(‘&u_name’) or a.sid = &s_id )

and a.paddr = c.addr

/

Oracle, SQL scripts

Post navigation

Previous Post: All About Trace Fils
Next Post: How to check current redo log progress redo_progress.sql

Related Posts

  • EXTPROC Oracle
  • Good Doc 28-JUN-2006 Oracle
  • USER_TABLES.Freelists Oracle
  • Resolving RMAN Hung Jobs Oracle
  • Committing distributed transaction using commit force Oracle
  • Good Link from metalink 1 Oracle

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

Categories

  • AWS (2)
  • Azure (1)
  • Linux/Unix (149)
  • Oracle (392)
  • PHP/MYSQL/Wordpress (10)
  • Power-BI (0)
  • Python/PySpark (7)
  • RAC (17)
  • rman-dataguard (26)
  • shell (149)
  • SQL scripts (341)
  • Uncategorized (0)
  • Videos (0)

Recent Posts

  • load SPM baseline from cursor cache05-Jun-2025
  • Drop all SPM baselines for SQL handle05-Jun-2025
  • Load SPM baseline from AWR05-Jun-2025
  • Drop specific SQL plan baseline – spm05-Jun-2025
  • findinfo.sql (SQL for getting CPU and Active session info)27-May-2025
  • SQL Tracker by SID sqltrackerbysid.sql22-Apr-2025
  • How to connect to Oracle Database with Wallet with Python.21-Mar-2025
  • JSON/XML Types in Oracle18-Mar-2025
  • CPU Core related projections12-Mar-2025
  • Exadata Basics10-Dec-2024

Archives

  • 2025
  • 2024
  • 2023
  • 2010
  • 2009
  • 2008
  • 2007
  • 2006
  • 2005
  • Configure ssh authentications for RAC Oracle
  • setting prompt display with .profile Linux/Unix
  • Sending email with file attachment. Linux/Unix
  • Goldengate document from Porus Oracle
  • Windows based Command line mailing program like mailx (Sednmail for windows) PHP/MYSQL/Wordpress
  • How to specify 2 arch location to avoid any kind of DB hanging. Oracle
  • Getting started with notebook Python/PySpark
  • Changing the Global Database Name Oracle

Copyright © 2025 pvmehta.com.

Powered by PressBook News WordPress theme