Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Mailing Lists -> Oracle-L -> RE: SELECT Output Default Ordering ?

RE: SELECT Output Default Ordering ?

From: DENNIS WILLIAMS <DWILLIAMS_at_LIFETOUCH.COM>
Date: Wed, 25 Jun 2003 13:08:28 -0700
Message-ID: <F001.005B9BD7.20030625125758@fatcity.com>


Tanel

   No ORDER BY. It upsets we DBAs, but some sites purchase Oracle and don't hire a DBA. Especially smaller sites. Naturally Oracle doesn't want to make it sound like they must have a DBA or the customer will probably buy MS SQL. So as a vendor you must have your application run reasonably well with no tuning if you want to sell to small sites. Otherwise the customer will blame you for a fussy application. If you add an ORDER BY, sometimes Oracle will decide it needs to sort, or at least that is the fear. The method I describe has worked pretty well over many Oracle versions (I think one of the Oracle 7.1 versions ignored hints). And yes, if an index is missing, it doesn't blow up, it just gets really sloooooow. But it makes sense to the customer that if they dropped an index that things foul up. Then they don't blame the vendor, just recreate the index and remember to not get so creative next time.

   I think the lesson here is that as a DBA you need to support certain applications and understand WHY the vendor did certain things a particular way. Right now my learning project is E.piphany so if anyone on the list works with that, please drop me a private note.

Dennis Williams
DBA, 80%OCP, 100% DBA
Lifetouch, Inc.
[EMAIL PROTECTED] -----Original Message-----
Sent: Wednesday, June 25, 2003 1:05 PM
To: Multiple recipients of list ORACLE-L

> Vivek
> If you want the data returned in an order, you can create an index with
> the order you want, and in your query provide a hint for Oracle to use
that
> index. If your query is such that Oracle actually uses that index, the
data
> will be returned in that order. I work with a large application that
> entirely depends on this principle. Crude but nevertheless effective.

Ouch!!!

Or did you mean that you still use ORDER BY, but index scan helps to avoid sorting?

What if this index becomes invalid for some reason, your hint won't be used, and if you don't have order by, your application will fail big time!

Tanel.

-- 
Please see the official ORACLE-L FAQ: http://www.orafaq.net
-- 
Author: Tanel Poder
  INET: [EMAIL PROTECTED]

Fat City Network Services    -- 858-538-5051 http://www.fatcity.com
San Diego, California        -- Mailing list and web hosting services
---------------------------------------------------------------------
To REMOVE yourself from this mailing list, send an E-Mail message
to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
also send the HELP command for other information (like subscribing).
-- 
Please see the official ORACLE-L FAQ: http://www.orafaq.net
-- 
Author: DENNIS WILLIAMS
  INET: [EMAIL PROTECTED]

Fat City Network Services    -- 858-538-5051 http://www.fatcity.com
San Diego, California        -- Mailing list and web hosting services
---------------------------------------------------------------------
To REMOVE yourself from this mailing list, send an E-Mail message
to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
also send the HELP command for other information (like subscribing).
Received on Wed Jun 25 2003 - 15:08:28 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US