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: Decode() function fails in 8.1.5/Linux

Re: Decode() function fails in 8.1.5/Linux

From: QuestionExchange <USENET_at_questionexchange.com>
Date: 13 Dec 1999 15:40:14 GMT
Message-ID: <2952qx@questionexchange.com>


Perhaps you should start with the problem that the "foo" is  probably not what you meant but actually wanted 'foo'. "foo" implies you have a column called foo (in small letters) and it is being compared with
whatever gb_attribute might be.
Give me one - real cut/paste example of what you are really doing and some example rows.
Becca
> I'm running 8.1.5 (8i) Enterprise Edition on RedHat Linux,
and trying
> to execute some of the queries from the TPC-D benchmark suite
(for
> research).
>
> Infortunately, all of the queries with the decode() function
in the
> select list fail. They all take the default value no matter
what the
> other inputs are, it seems.
>
> The pattern is
> select
> decode(gb_attribute, "foo", expr, 0)
> from
> <some tables>
> where
> <some conditions>
> group by
> gb_attribute,
> <and possibly some others>
>
> Now it does seem that this should work: the group-by
attribute
> is available, and constant per output row. However, the
result
> is always zero.
>
> Any clues out there? Any confirmation that this happens
elsewhere?
>
>
> --
> Kevin O'Gorman (805) 650-6274 kogorman_at_pacbell.net
> At school: kogorman_at_cs.ucsb.edu
> Permanent e-mail forwarder:

Kevin.O'Gorman.64_at_Alum.Dartmouth.org
>
>

--
  This answer is courtesy of QuestionExchange.com   http://www.questionexchange.com/showUsenetGuest.jhtml?ans_id=8222&cus_id=USENET&qtn_id=7338 Received on Mon Dec 13 1999 - 09:40:14 CST

Original text of this message

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