码迷,mamicode.com
首页 > 数据库 > 详细

查询Oracle sql语句中绑定变量值的方法

时间:2015-05-01 23:54:09      阅读:190      评论:0      收藏:0      [点我收藏+]

标签:

alter session set nls_date_format = 'yyyy-mm-dd,hh24:mi:ss';

set linesize 400

col sql_Id format a20

col name format a20

col datatype_string format a14

col value_string format a20




select sql_id,name, datatype_string, last_captured,value_string from v$sql_bind_capture where sql_id='dxfcacn4t4ppw' order by LAST_CAPTURED,POSITION;

--在出问题的实例上执行,请自行替换sql_id,此时该sql还在shared pool中,没有被aged out




select instance_number,  sql_id,name, datatype_string, last_captured,value_string from dba_hist_sqlbind where sql_id='fahv8x6ngrb50'order by LAST_CAPTURED,POSITION;

--请自行替换sql_id,此时是从awr中查询。

查询Oracle sql语句中绑定变量值的方法

标签:

原文地址:http://blog.csdn.net/msdnchina/article/details/45423559

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!