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

Home -> Community -> Usenet -> c.d.o.misc -> Re: if then else statement on 2 columns in SQL query?

Re: if then else statement on 2 columns in SQL query?

From: Ken Madsen <madsenkj_at_no-spampe-nelson.com>
Date: Mon, 19 Oct 1998 13:15:22 -0700
Message-ID: <362B9DDA.DBBBBACE@no-spampe-nelson.com>


You could try to create a duplicate decode nested structure. Except for any of the final results replace 'Oranges' with the sort order '1'

Like this:

  Decode (Col_1, 'O' , 'Orange', decode... ...) Data,   Decode (Col_1, 'O' , 1 , decode... ...) Sort_Order
.
.

  Order by Sort_Order

Think this will work?

--
Ken Madsen Received on Mon Oct 19 1998 - 15:15:22 CDT

Original text of this message

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