zoukankan      html  css  js  c++  java
  • 根据请求号(request ID)查找正在运行的sql

    --下面的SQL可以根据Request ID找到对应的Session信息:

    select *

    from v$session

    where paddr in

    (select addr

    from v$process

    where spid =

    (select b.oracle_process_id

    from apps.fnd_concurrent_requests b

    where b.request_id = &req_number))

     

    --或者进一步找到正在运行的SQL:

    select sql_text

    from v$sqltext_with_newlines

    where hash_value in

    (select SQL_HASH_VALUE

    from v$session

    where paddr in

    (select addr

    from v$process

    where spid =

    (select b.oracle_process_id

    from apps.fnd_concurrent_requests b

    where b.request_id = &req_number)))

    order by piece;

     

    --通过request id sql id找到相关脚本

    SELECT ses.sid,

            ses.serial# ,

            Ses.sql_id

         FROM v$session ses,

            v$process pro

            WHERE ses.paddr = pro.addr

                 AND pro.spid IN (SELECT oracle_process_id

                      FROM fnd_concurrent_requests

                      WHERE request_id = <request_id>);

    select sql_text from v$sqltext where sql_id='0kkhhb2w93cx0' order by piece

  • 相关阅读:
    httpd添加新模块
    编译httpd细节
    apache配置文件说明及一些指令
    xen原理
    EXSI的使用
    VMWare ESX server安装
    虚拟化技术
    Kvm命令集管理虚拟机
    RAID几种方式
    BZOJ1011 [HNOI2008]遥远的行星 【奇技淫巧】
  • 原文地址:https://www.cnblogs.com/quanweiru/p/9128161.html
Copyright © 2011-2022 走看看