<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	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:georss="http://www.georss.org/georss" xmlns:geo="http://www.w3.org/2003/01/geo/wgs84_pos#" xmlns:media="http://search.yahoo.com/mrss/"
		>
<channel>
	<title>Comments on: Sorting</title>
	<atom:link href="http://jonathanlewis.wordpress.com/2007/06/03/sorting/feed/" rel="self" type="application/rss+xml" />
	<link>http://jonathanlewis.wordpress.com/2007/06/03/sorting/</link>
	<description>Just another Oracle weblog</description>
	<lastBuildDate>Mon, 20 May 2013 17:10:14 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.com/</generator>
	<item>
		<title>By: Jonathan Lewis</title>
		<link>http://jonathanlewis.wordpress.com/2007/06/03/sorting/#comment-31103</link>
		<dc:creator><![CDATA[Jonathan Lewis]]></dc:creator>
		<pubDate>Tue, 27 May 2008 09:54:26 +0000</pubDate>
		<guid isPermaLink="false">http://jonathanlewis.wordpress.com/2007/06/03/sorting/#comment-31103</guid>
		<description><![CDATA[Hermant,

There&#039;s not a lot that can be said, really.

What I&#039;d like to see is a little more detail of why it can happen - are there any features like &quot;number of columns in a multi-column sort&quot;, &quot;critical byte length of the things being sorted&quot;, &quot;some aspect of number of concurrent sorts&quot; - and so on.  

There has to be something more than &quot;it happens at random&quot;, or they wouldn&#039;t be able to fix it.  (And if it is a bug that means it can &lt;b&gt;seem&lt;/b&gt; to happen at random I&#039;d like to know that too).]]></description>
		<content:encoded><![CDATA[<p>Hermant,</p>
<p>There&#8217;s not a lot that can be said, really.</p>
<p>What I&#8217;d like to see is a little more detail of why it can happen &#8211; are there any features like &#8220;number of columns in a multi-column sort&#8221;, &#8220;critical byte length of the things being sorted&#8221;, &#8220;some aspect of number of concurrent sorts&#8221; &#8211; and so on.  </p>
<p>There has to be something more than &#8220;it happens at random&#8221;, or they wouldn&#8217;t be able to fix it.  (And if it is a bug that means it can <b>seem</b> to happen at random I&#8217;d like to know that too).</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Hemant K Chitale</title>
		<link>http://jonathanlewis.wordpress.com/2007/06/03/sorting/#comment-31091</link>
		<dc:creator><![CDATA[Hemant K Chitale]]></dc:creator>
		<pubDate>Mon, 26 May 2008 06:47:36 +0000</pubDate>
		<guid isPermaLink="false">http://jonathanlewis.wordpress.com/2007/06/03/sorting/#comment-31091</guid>
		<description><![CDATA[I came across MetaLink Note#6817844.8 titled &quot;Bug 6817844 - Multi pass sort with auto memory management even with plenty of PGA&quot;

I&#039;ll try to build a test case if I have time tonight.

However, would you care to comment on the Bug ?]]></description>
		<content:encoded><![CDATA[<p>I came across MetaLink Note#6817844.8 titled &#8220;Bug 6817844 &#8211; Multi pass sort with auto memory management even with plenty of PGA&#8221;</p>
<p>I&#8217;ll try to build a test case if I have time tonight.</p>
<p>However, would you care to comment on the Bug ?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Jonathan Lewis</title>
		<link>http://jonathanlewis.wordpress.com/2007/06/03/sorting/#comment-16853</link>
		<dc:creator><![CDATA[Jonathan Lewis]]></dc:creator>
		<pubDate>Thu, 02 Aug 2007 15:43:40 +0000</pubDate>
		<guid isPermaLink="false">http://jonathanlewis.wordpress.com/2007/06/03/sorting/#comment-16853</guid>
		<description><![CDATA[Dan,
In a case like this you really can&#039;t comment until you&#039;ve checked the execution plan. A possible explanation for the difference could simply be that 8i used a hash join and 10g used a nested loop with index on the second table.]]></description>
		<content:encoded><![CDATA[<p>Dan,<br />
In a case like this you really can&#8217;t comment until you&#8217;ve checked the execution plan. A possible explanation for the difference could simply be that 8i used a hash join and 10g used a nested loop with index on the second table.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Dan</title>
		<link>http://jonathanlewis.wordpress.com/2007/06/03/sorting/#comment-16544</link>
		<dc:creator><![CDATA[Dan]]></dc:creator>
		<pubDate>Tue, 31 Jul 2007 02:06:52 +0000</pubDate>
		<guid isPermaLink="false">http://jonathanlewis.wordpress.com/2007/06/03/sorting/#comment-16544</guid>
		<description><![CDATA[I saw another case but am not sure if it&#039;s related to the &quot;newsort&quot; (tried to disable it without luck):

drop table p purge;
drop table c purge;
create table p (c1 varchar2(10));

insert into p values(&#039;C001&#039;);
insert into p values(&#039;T001&#039;);

create index idx$p on p(c1);

create table c (c1 varchar2(10), c2 number);

insert into c values(&#039;C001&#039;, 1);
insert into c values(&#039;C001&#039;, 2);
insert into c values(&#039;C001&#039;, 3);

insert into c values(&#039;T001&#039;, 3);
insert into c values(&#039;T001&#039;, 2);
insert into c values(&#039;T001&#039;, 1);

create index idx$c on c(c1, c2);

select p.c1, c.c2
  from p, c
where p.c1 = c.c1
order by 1
/

-- From 8i: c2 shown in the inserted order
C1     C2
----------
C001  1
C001  2
C001  3
T001  3
T001  2
T001  1

-- From 10g: c2 shown in the &quot;asc&quot; order
C1     C2
----------
C001  1
C001  2
C001  3
T001  1
T001  2
T001  3

Acutally, the query shows the same with or without &quot;order by&quot; clause in both 8i and 10gR2.]]></description>
		<content:encoded><![CDATA[<p>I saw another case but am not sure if it&#8217;s related to the &#8220;newsort&#8221; (tried to disable it without luck):</p>
<p>drop table p purge;<br />
drop table c purge;<br />
create table p (c1 varchar2(10));</p>
<p>insert into p values(&#8216;C001&#8242;);<br />
insert into p values(&#8216;T001&#8242;);</p>
<p>create index idx$p on p(c1);</p>
<p>create table c (c1 varchar2(10), c2 number);</p>
<p>insert into c values(&#8216;C001&#8242;, 1);<br />
insert into c values(&#8216;C001&#8242;, 2);<br />
insert into c values(&#8216;C001&#8242;, 3);</p>
<p>insert into c values(&#8216;T001&#8242;, 3);<br />
insert into c values(&#8216;T001&#8242;, 2);<br />
insert into c values(&#8216;T001&#8242;, 1);</p>
<p>create index idx$c on c(c1, c2);</p>
<p>select p.c1, c.c2<br />
  from p, c<br />
where p.c1 = c.c1<br />
order by 1<br />
/</p>
<p>&#8211; From 8i: c2 shown in the inserted order<br />
C1     C2<br />
&#8212;&#8212;&#8212;-<br />
C001  1<br />
C001  2<br />
C001  3<br />
T001  3<br />
T001  2<br />
T001  1</p>
<p>&#8211; From 10g: c2 shown in the &#8220;asc&#8221; order<br />
C1     C2<br />
&#8212;&#8212;&#8212;-<br />
C001  1<br />
C001  2<br />
C001  3<br />
T001  1<br />
T001  2<br />
T001  3</p>
<p>Acutally, the query shows the same with or without &#8220;order by&#8221; clause in both 8i and 10gR2.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Jonathan Lewis</title>
		<link>http://jonathanlewis.wordpress.com/2007/06/03/sorting/#comment-11332</link>
		<dc:creator><![CDATA[Jonathan Lewis]]></dc:creator>
		<pubDate>Tue, 05 Jun 2007 07:18:22 +0000</pubDate>
		<guid isPermaLink="false">http://jonathanlewis.wordpress.com/2007/06/03/sorting/#comment-11332</guid>
		<description><![CDATA[Neeraj, it is important to realise that &lt;b&gt;neither&lt;/b&gt; vesion is &lt;i&gt;&#039;working fine&#039;&lt;/i&gt;, or displaying a &lt;i&gt;&#039;glitch&#039;&lt;/i&gt;. 

Any apparent ordering that has not been specified is simply a side-effect of implementation, and is therefore neither right nor wrong.

10.1 shows the old behaviour because the new sort (like the new &lt;b&gt;hash group by&lt;/b&gt;) was introduced in 10.2]]></description>
		<content:encoded><![CDATA[<p>Neeraj, it is important to realise that <b>neither</b> vesion is <i>&#8216;working fine&#8217;</i>, or displaying a <i>&#8216;glitch&#8217;</i>. </p>
<p>Any apparent ordering that has not been specified is simply a side-effect of implementation, and is therefore neither right nor wrong.</p>
<p>10.1 shows the old behaviour because the new sort (like the new <b>hash group by</b>) was introduced in 10.2</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Neeraj</title>
		<link>http://jonathanlewis.wordpress.com/2007/06/03/sorting/#comment-11170</link>
		<dc:creator><![CDATA[Neeraj]]></dc:creator>
		<pubDate>Mon, 04 Jun 2007 13:00:00 +0000</pubDate>
		<guid isPermaLink="false">http://jonathanlewis.wordpress.com/2007/06/03/sorting/#comment-11170</guid>
		<description><![CDATA[Same set of data is working fine in Oracle 10.1.0.2, that is its giving next priority to rowid if the order by column has same values.

Also , For same data if you use nvl(c,0) in the order by clause, than again some glitch in sorting.]]></description>
		<content:encoded><![CDATA[<p>Same set of data is working fine in Oracle 10.1.0.2, that is its giving next priority to rowid if the order by column has same values.</p>
<p>Also , For same data if you use nvl(c,0) in the order by clause, than again some glitch in sorting.</p>
]]></content:encoded>
	</item>
</channel>
</rss>
