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 -> Stupid SQL question

Stupid SQL question

From: Marcy A. McKee <marcy_at_decisionism.com>
Date: Thu, 28 May 1998 12:04:01 -0600
Message-ID: <356DA711.5DF8B02D@decisionism.com>


Hello,
I have the following query:
select city || '-NE' from blah where city = 'OMAHA' and state = 'NEBRASKA'
that works the way I want it to. My problem is that I want to include an additional statement like
select city || '-IA' from blah where city = 'OMAHA' and state = 'IOWA' so that my end result is OMAHA-NE when the state is equal to Nebraska and OMAHA-IA when the state is equal to Iowa. Any ideas on how to do this?

Thanks,
Marcy Received on Thu May 28 1998 - 13:04:01 CDT

Original text of this message

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