List:General Discussion« Previous MessageNext Message »
From:Michael Widenius Date:September 8 1999 5:18pm
Subject:Re: BUG: default order by error in 3.23.2
View as plain text  
>>>>> "Jules" == Jules Bean <jmlb2@stripped> writes:

Jules> Michael Widenius wrote:
>> 
>> >>>>> "Peter" == =?ISO-8859-1?Q?Peter Str=F6mberg?=
> <ISO-8859-1> writes:
>> 
Peter> Den 8 Sep 99, klockan 12:09
Peter> skrev Michael Widenius om (Re: BUG: default order by error in ):
>> 
>> >>
>> >> The MySQL user pointed that pointed this out for me was referring to a
>> >> explicit statement in 'SQL for dummies' that described this
>> >> behaveour.  (Sorry about the title, but this is the only book where I
>> >> have found a description of the behaveour of ORDER BY and DESC)
>> >>
>> >> I tried to confirm this from C.J.Date's book 'The SQL standard' and
> from
>> >> 'Using SQL' but neither of these touched the topic of ORDER BY with
>> >> more than 1 elements where DESC is first.
>> >>
>> >> I will add a test in crash-me so that we can check how other databases
>> >> does this!
>> >>
>> 
Peter> Sybase (SQL Server Reference Manual):
Peter> If you do not specify asc or desc, asc is assumed.
>> 
Peter> order by a desc, b, c <==> order by a desc, b asc, c asc
>> 
Peter> Informix (Guide to SQL, Tutorial):
Peter> SELECT customer_num, order_num, po_num, order_date
Peter> FROM orders
Peter> ORDER BY order_date DESC, customer_num
>> 
Peter> In this case, data is first sorted in descending order by order_date and in
Peter> ascending order by customer_num.
>> 
Peter> /Peter
>> 
>> Thanks!
>> 
>> Can anyone else verify the above in some book that describes the ANSI
>> SQL standard ?
>> 

Jules> Unfortunately, ANSI and ISO are both too stuck in the past to make their
Jules> standards available on the web (they want to make money out of them).

Jules> So I can only quote circumstantial evidence:

Jules> An online oracle manual:

Jules> http://www.itlibrary.com/reference/library/0672310252/ch06.html#Heading19

Jules> An oxford university SQL course:

Jules> http://www.oucs.ox.ac.uk/software/sqlnotes.html#order


Jules> Jules


Ok.  It looks like 'SQL for dummies' was wrong;  I will fix this in
3.23.3 to be as before!

Regards,
Monty
Thread
BUG: default order by error in 3.23.2Brian Moon5 Sep
  • Re: BUG: default order by error in 3.23.2Sasha Pachev6 Sep
  • Re: BUG: default order by error in 3.23.2Brian Moon7 Sep
    • Re: BUG: default order by error in 3.23.2Michael Widenius8 Sep
  • Re: BUG: default order by error in 3.23.2Brian Moon8 Sep
    • Re: BUG: default order by error in 3.23.2Michael Widenius8 Sep
      • Re: BUG: default order by error in 3.23.2Peter Strömberg8 Sep
        • Re: BUG: default order by error in 3.23.2Michael Widenius8 Sep
    • Re: BUG: default order by error in 3.23.2Jules Bean8 Sep
      • Re: BUG: default order by error in 3.23.2Michael Widenius8 Sep