<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>天道酬勤 &#187; Useful Script</title>
	<atom:link href="http://www.ochef.net/tag/script/feed" rel="self" type="application/rss+xml" />
	<link>http://www.ochef.net</link>
	<description>Oracle and My Life</description>
	<lastBuildDate>Mon, 09 Jan 2012 05:39:00 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>查询隐含参数的代码</title>
		<link>http://www.ochef.net/2009/05/implicit-parameter-query-code.html</link>
		<comments>http://www.ochef.net/2009/05/implicit-parameter-query-code.html#comments</comments>
		<pubDate>Tue, 12 May 2009 05:32:58 +0000</pubDate>
		<dc:creator>ochef</dc:creator>
				<category><![CDATA[dba-script]]></category>
		<category><![CDATA[Useful Script]]></category>

		<guid isPermaLink="false">http://www.ochef.net/?p=334</guid>
		<description><![CDATA[下面代码可用于查询系统中所有的隐含参数，Coding来自eygle的著作《深入浅出Oracle》。再次精读这本书，以前对Oracle的理解一些模糊的地方慢慢清晰起来，告诫自己，继续努力！ Coding: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 SQL&#62;select x.ksppinm name, y.ksppstvl VALUE, y.ksppstdf isdefault, decode&#40;bitand&#40;y.ksppstvf,7&#41;,1,'MODIFIED',4,'SYSTEM_MOD','FALSE'&#41; ismod, decode&#40;bitand&#40;y.ksppstvf,2&#41;,2,'TRUE','FALSE'&#41; isadj FROM sys.x$ksppi x, sys.x$ksppcv y WHERE x.inst_id=userenv&#40;'Instance'&#41; AND y.inst_id=userenv&#40;'Instance'&#41; AND x.indx=y.indx AND x.ksppinm LIKE '%_&#38;par%' ORDER BY translate&#40;x.ksppinm,'_',''&#41;; Enter VALUE FOR par: shared_pool_reserved_min_alloc OLD 14: x.ksppinm [...]<table class="wumii-related-items" cellspacing="0" cellpadding="2" border="0" width="100%" style="clear: both;">
    
    <tr>
        <td ><b><font size="-1"  style="display: block !important; padding: 20px 0 5px !important;">您可能也喜欢：</font></b></td>
    </tr>
    
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.ochef.net%2F2009%2F11%2Faix-using-raw-create-a-non-rac-of-the-asm.html&from=http%3A%2F%2Fwww.ochef.net%2F2009%2F05%2Fimplicit-parameter-query-code.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">AIX下使用 raw 创建 non-rac 的ASM</font>
                    </a>
                </td>
            </tr>
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.ochef.net%2F2009%2F11%2Fsrvctl-use-xiangjie.html&from=http%3A%2F%2Fwww.ochef.net%2F2009%2F05%2Fimplicit-parameter-query-code.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">RAC常用开启关闭命令 – SRVCTL用法</font>
                    </a>
                </td>
            </tr>
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.ochef.net%2F2010%2F08%2Fbaby-we-love-you.html&from=http%3A%2F%2Fwww.ochef.net%2F2009%2F05%2Fimplicit-parameter-query-code.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">Baby,we love you!</font>
                    </a>
                </td>
            </tr>
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.ochef.net%2F2009%2F09%2Finstall-ids-11-5-uc5-for-linux.html&from=http%3A%2F%2Fwww.ochef.net%2F2009%2F05%2Fimplicit-parameter-query-code.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">Install IDS 11.5 UC5 for Linux</font>
                    </a>
                </td>
            </tr>
    
    <tr>
        <td  align="right">
            <a style="text-decoration: none !important;" href="http://www.wumii.com/widget/relatedItems.htm" target="_blank" title="无觅相关文章插件">
                <font size="-1" color="#bbbbbb" style="display: block !important; font-family: arial !important; padding: 5px 0 !important; font-size: 12px !important; color: #bbb !important;">无觅</font>
            </a>
        </td>
    </tr>
</table>]]></description>
			<content:encoded><![CDATA[<p>下面代码可用于查询系统中所有的隐含参数，Coding来自eygle的著作《深入浅出Oracle》。再次精读这本书，以前对Oracle的理解一些模糊的地方慢慢清晰起来，告诫自己，继续努力！<br />
Coding:</p>

<div class="wp_syntax"><table><tr><td class="line_numbers"><pre>1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
</pre></td><td class="code"><pre class="sql" style="font-family:monospace;">SQL<span style="color: #66cc66;">&gt;</span>select 
   x<span style="color: #66cc66;">.</span>ksppinm   name<span style="color: #66cc66;">,</span>
   y<span style="color: #66cc66;">.</span>ksppstvl  <span style="color: #993333; font-weight: bold;">VALUE</span><span style="color: #66cc66;">,</span>
   y<span style="color: #66cc66;">.</span>ksppstdf  isdefault<span style="color: #66cc66;">,</span>
   decode<span style="color: #66cc66;">&#40;</span>bitand<span style="color: #66cc66;">&#40;</span>y<span style="color: #66cc66;">.</span>ksppstvf<span style="color: #66cc66;">,</span><span style="color: #cc66cc;">7</span><span style="color: #66cc66;">&#41;</span><span style="color: #66cc66;">,</span><span style="color: #cc66cc;">1</span><span style="color: #66cc66;">,</span><span style="color: #ff0000;">'MODIFIED'</span><span style="color: #66cc66;">,</span><span style="color: #cc66cc;">4</span><span style="color: #66cc66;">,</span><span style="color: #ff0000;">'SYSTEM_MOD'</span><span style="color: #66cc66;">,</span><span style="color: #ff0000;">'FALSE'</span><span style="color: #66cc66;">&#41;</span>  ismod<span style="color: #66cc66;">,</span>
   decode<span style="color: #66cc66;">&#40;</span>bitand<span style="color: #66cc66;">&#40;</span>y<span style="color: #66cc66;">.</span>ksppstvf<span style="color: #66cc66;">,</span><span style="color: #cc66cc;">2</span><span style="color: #66cc66;">&#41;</span><span style="color: #66cc66;">,</span><span style="color: #cc66cc;">2</span><span style="color: #66cc66;">,</span><span style="color: #ff0000;">'TRUE'</span><span style="color: #66cc66;">,</span><span style="color: #ff0000;">'FALSE'</span><span style="color: #66cc66;">&#41;</span>  isadj
   <span style="color: #993333; font-weight: bold;">FROM</span>
     sys<span style="color: #66cc66;">.</span>x$ksppi   x<span style="color: #66cc66;">,</span>
     sys<span style="color: #66cc66;">.</span>x$ksppcv  y
   <span style="color: #993333; font-weight: bold;">WHERE</span>
     x<span style="color: #66cc66;">.</span>inst_id<span style="color: #66cc66;">=</span>userenv<span style="color: #66cc66;">&#40;</span><span style="color: #ff0000;">'Instance'</span><span style="color: #66cc66;">&#41;</span> <span style="color: #993333; font-weight: bold;">AND</span>
     y<span style="color: #66cc66;">.</span>inst_id<span style="color: #66cc66;">=</span>userenv<span style="color: #66cc66;">&#40;</span><span style="color: #ff0000;">'Instance'</span><span style="color: #66cc66;">&#41;</span> <span style="color: #993333; font-weight: bold;">AND</span>
     x<span style="color: #66cc66;">.</span>indx<span style="color: #66cc66;">=</span>y<span style="color: #66cc66;">.</span>indx <span style="color: #993333; font-weight: bold;">AND</span>
     x<span style="color: #66cc66;">.</span>ksppinm <span style="color: #993333; font-weight: bold;">LIKE</span> <span style="color: #ff0000;">'%_&amp;par%'</span>
   <span style="color: #993333; font-weight: bold;">ORDER</span> <span style="color: #993333; font-weight: bold;">BY</span>
     translate<span style="color: #66cc66;">&#40;</span>x<span style="color: #66cc66;">.</span>ksppinm<span style="color: #66cc66;">,</span><span style="color: #ff0000;">'_'</span><span style="color: #66cc66;">,</span><span style="color: #ff0000;">''</span><span style="color: #66cc66;">&#41;</span>;</pre></td></tr></table></div>


<div class="wp_syntax"><div class="code"><pre class="sql" style="font-family:monospace;">Enter <span style="color: #993333; font-weight: bold;">VALUE</span> <span style="color: #993333; font-weight: bold;">FOR</span> par: shared_pool_reserved_min_alloc
<span style="color: #993333; font-weight: bold;">OLD</span>  <span style="color: #cc66cc;">14</span>:      x<span style="color: #66cc66;">.</span>ksppinm <span style="color: #993333; font-weight: bold;">LIKE</span> <span style="color: #ff0000;">'%_&amp;par%'</span>
<span style="color: #993333; font-weight: bold;">NEW</span>  <span style="color: #cc66cc;">14</span>:      x<span style="color: #66cc66;">.</span>ksppinm <span style="color: #993333; font-weight: bold;">LIKE</span> <span style="color: #ff0000;">'%_shared_pool_reserved_min_alloc%'</span>
&nbsp;
NAME                                <span style="color: #993333; font-weight: bold;">VALUE</span>        ISDEFAULT ISMOD      ISADJ
<span style="color: #808080; font-style: italic;">----------------------------------- ------------ --------- ---------- -----</span>
_shared_pool_reserved_min_alloc     <span style="color: #cc66cc;">4400</span>         <span style="color: #993333; font-weight: bold;">TRUE</span>      <span style="color: #993333; font-weight: bold;">FALSE</span>      <span style="color: #993333; font-weight: bold;">FALSE</span></pre></div></div>

<p>-The End-</p>
<table class="wumii-related-items" cellspacing="0" cellpadding="2" border="0" width="100%" style="clear: both;">
    
    <tr>
        <td ><b><font size="-1"  style="display: block !important; padding: 20px 0 5px !important;">您可能也喜欢：</font></b></td>
    </tr>
    
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.ochef.net%2F2009%2F11%2Faix-using-raw-create-a-non-rac-of-the-asm.html&from=http%3A%2F%2Fwww.ochef.net%2F2009%2F05%2Fimplicit-parameter-query-code.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">AIX下使用 raw 创建 non-rac 的ASM</font>
                    </a>
                </td>
            </tr>
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.ochef.net%2F2009%2F11%2Fsrvctl-use-xiangjie.html&from=http%3A%2F%2Fwww.ochef.net%2F2009%2F05%2Fimplicit-parameter-query-code.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">RAC常用开启关闭命令 – SRVCTL用法</font>
                    </a>
                </td>
            </tr>
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.ochef.net%2F2011%2F04%2Fdust-in-mind-a-bad-experience-x200.html&from=http%3A%2F%2Fwww.ochef.net%2F2009%2F05%2Fimplicit-parameter-query-code.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">记X200一次糟糕的除尘经历</font>
                    </a>
                </td>
            </tr>
            <tr>
                <td style="margin: 0 !important; padding: 0 !important; line-height: 20px !important;">
                    <img border="0" src="http://static.wumii.com/images/widget/widget_solidPoint.gif">
                    <a target="_blank" style="text-decoration: none !important;" href="http://app.wumii.com/ext/redirect.htm?url=http%3A%2F%2Fwww.ochef.net%2F2009%2F09%2Fdb2_vs_oracle_01.html&from=http%3A%2F%2Fwww.ochef.net%2F2009%2F05%2Fimplicit-parameter-query-code.html">
                        <font size="-1" color="#333333" style="line-height: 1.65em; font-size: 12px !important;">DB2对比Oracle学习系列之:instance &amp; database concepts</font>
                    </a>
                </td>
            </tr>
    
    <tr>
        <td  align="right">
            <a style="text-decoration: none !important;" href="http://www.wumii.com/widget/relatedItems.htm" target="_blank" title="无觅相关文章插件">
                <font size="-1" color="#bbbbbb" style="display: block !important; font-family: arial !important; padding: 5px 0 !important; font-size: 12px !important; color: #bbb !important;">无觅</font>
            </a>
        </td>
    </tr>
</table>]]></content:encoded>
			<wfw:commentRss>http://www.ochef.net/2009/05/implicit-parameter-query-code.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

