<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=Content-Type content="text/html; charset=us-ascii">
<META content="MSHTML 6.00.6001.18203" name=GENERATOR></HEAD>
<BODY>
<DIV dir=ltr align=left><FONT face="Lucida Sans" color=#000080 size=2><SPAN 
class=091254415-18032009>Option #1 is the only feasible one, because in MySQL we 
need to wrap the expression:</SPAN></FONT></DIV>
<DIV dir=ltr align=left><FONT face="Lucida Sans" color=#000080 size=2><SPAN 
class=091254415-18032009></SPAN></FONT>&nbsp;</DIV>
<DIV dir=ltr align=left><FONT face="Lucida Sans" color=#000080 size=2><SPAN 
class=091254415-18032009>e DESC --&gt; ISNULL(e), e DESC</SPAN></FONT></DIV>
<DIV dir=ltr align=left><FONT face="Lucida Sans" color=#000080 size=2><SPAN 
class=091254415-18032009></SPAN></FONT>&nbsp;</DIV>
<DIV dir=ltr align=left><FONT face="Lucida Sans" color=#000080 size=2><SPAN 
class=091254415-18032009>But I'm pretty sure that Oracle puts nulls last by 
default. So, the query should be producing the correct result as it 
stands.</SPAN></FONT></DIV><FONT face="Lucida Sans" color=#000080 
size=2></FONT><FONT face="Lucida Sans" color=#000080 size=2></FONT><BR>
<BLOCKQUOTE dir=ltr 
style="PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #000080 2px solid; MARGIN-RIGHT: 0px">
  <DIV class=OutlookMessageHeader lang=en-us dir=ltr align=left>On another note, 
  I'm not sure that testNullCollation was ever testing what it was intended to. 
  &nbsp;It appears to be testing the the ordering of members with NULL ordinals 
  correctly puts them at the end. &nbsp;The [HQ] member in the test is set to 
  have a null ordinal. &nbsp;The query used in the test, however, uses a 
  topcount function, and HQ does not fall into the topcount set. &nbsp;So this 
  would never actually validate that HQ was placed at the end.<SPAN 
  class=091254415-18032009><FONT face="Lucida Sans" color=#000080 
  size=2>&nbsp;</FONT></SPAN></DIV></BLOCKQUOTE>
<DIV class=gmail_quote dir=ltr><SPAN class=091254415-18032009><FONT 
face="Lucida Sans" color=#000080 size=2>I may be wrong, but my impression is 
that testNullCollation is testing the ordering of null cells, not null 
members.&nbsp;The topCount generates select ... group by sum(...) order by 
sum(...) to retrieve the cells in sorted order, and we want cells whose values 
are nulls to appear last.</FONT></SPAN></DIV>
<DIV class=gmail_quote dir=ltr><SPAN class=091254415-18032009><FONT 
face="Lucida Sans" color=#000080 size=2></FONT></SPAN>&nbsp;</DIV>
<DIV class=gmail_quote dir=ltr><SPAN class=091254415-18032009><FONT 
face="Lucida Sans" color=#000080 size=2>Julian</FONT></SPAN></DIV>
<DIV class=gmail_quote dir=ltr><FONT face="Lucida Sans" color=#000080 
size=2></FONT>&nbsp;</DIV></BODY></HTML>