RE: Doubt related UPPER with spatial

  • From: Jackie Brock <J.Brock@xxxxxxxxxxxxx>
  • To: "ecandrietta@xxxxxxxxx" <ecandrietta@xxxxxxxxx>, ORACLE-L <oracle-l@xxxxxxxxxxxxx>
  • Date: Thu, 15 Mar 2012 11:40:44 -0600

What does the first query return?

-----Original Message-----
From: oracle-l-bounce@xxxxxxxxxxxxx [mailto:oracle-l-bounce@xxxxxxxxxxxxx] On 
Behalf Of Eriovaldo Andrietta
Sent: Thursday, March 15, 2012 11:35 AM
To: ORACLE-L
Subject: Doubt related UPPER with spatial

Hello friends:
I have the following doubt related to UPPER.

-- This sql does not run right
 SELECT tb1.id, upper('lote'),
              UPPER(tb2.FEATURE_TYPE),
              tb2.ID,
              tb2.feature_type,
              tb2.GEOMETRY
  FROM  CH   tb1,
              LOT tb2
 WHERE SDO_RELATE(tb2.GEOMETRY,tb1.GEOMETRY,'mask=inside querytype=WINDOW') = 
'TRUE'
      and UPPER(tb2.FEATURE_TYPE) = UPPER('lote')

-- This one run right
  SELECT tb1.id, upper('lote'),
              UPPER(tb2.FEATURE_TYPE),
              tb2.ID,
              tb2.feature_type,
              tb2.GEOMETRY
  FROM  CH   tb1,
              LOT tb2
 WHERE SDO_RELATE(tb2.GEOMETRY,tb1.GEOMETRY,'mask=inside querytype=WINDOW') = 
'TRUE'
      and tb2.FEATURE_TYPE = 'lote';

        ID UPPER('LOTE') UPPER(LOT_F.FEATURE_TYPE)
ID          FEATURE_TYPE
----------- -------------
----------------------------------------------------------------------
----------- ----------------
         86 LOTE
 LOTE
 92         lote
         93 LOTE
 LOTE
91         lote

The content of the column feature_type is:
FEATURE_TYPE
----------------------------------------------------------------------
lote
lote
lote
What is wrong ?
Why UPPER does not work in this case?
Any idea ?


Regards
Eriovaldo


--
//www.freelists.org/webpage/oracle-l


--
//www.freelists.org/webpage/oracle-l


Other related posts: