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: Spatial Cartidge - is a bug?

Re: Spatial Cartidge - is a bug?

From: Albert Godfrind <agodfrin_at_fr.oracle.com>
Date: Wed, 08 Sep 1999 18:34:49 +0200
Message-ID: <37D69029.1D4B9498@fr.oracle.com>


jst wrote:
>
> Thanks,
>
> but there appeared another error message:
>
> SQLWKS> execute
> bms_output.put_line( mdsys.SDO_WINDOW.BUILD_WINDOW('mdsys','EXAMPLE',1, 10,
> 100, 100,110,100,100,130) )
> ORA-13002: specified level is out of range
> ORA-06512: at "MDSYS.MD", line 597
> etc.
>
> In the Spatial Data Option Messages there is written:
> ORA-13002: specified level is out of range
> Cause: The specified level is either smaller than 1 or greater than the
> maximum level encoded in an HHCODE.
> Action: Verify that all levels are between 1 and the maximum number of
> levels encoded in the HHCODE
>
> What should I do, how can I find out and change the maximum number of levels
> encoded in the HHCODE??

Check the interface of the BUILD_WINDOW function. It expects the following arguments: (owner, layer_name, geometry_type, numtiles, x1,y1, x2,y2, ..., xn,Yn) where numtiles is not used (should be NULL).

In your case, the 1 that follows the layer name is interpreted as the geometry type (1 means it is a point), the 10 that follows is interpreted as the numtiles. The other numbers are the coordinates. I suspect that the error happens because the tiling algorithm tries to divide a single point in 10 tiles, which is impossible.

I suppose that what you want is to use a polygon window with corners (1,10) (100,100)
(110,100) (100,130). To get this, do the following:

declare
  window_gid number;
begin
  window_gid :=
    mdsys.SDO_WINDOW.BUILD_WINDOW ('mdsys','EXAMPLE',3, NULL,

         1, 10, 100,100, 110,100, 100,130, 1,10);   dbms_output.put_line ('Window GID is '|| window_gid); end;

The '3' is the geometry type (polygon). Notice numtiles is set to NULL, and that the polygon needs 5 points (the last point is repeated to it can close).

The returned GID number will be used as input to the RELATE functions.

/albert
--

Albert Godfrind         Oracle Data Server Division
Oracle Corporation      Multimedia and GeoSpatial Technologies
C.I.C.A                 Email:  agodfrin_at_fr.oracle.com    
2229 Route des Crêtes   Phone:  +33/4/92.94.21.37    
06560 Sophia-Antipolis  Mobile: +33/6/09.97.27.23    
France                  FAX:    +33/4/92.94.21.45    
                        http://www.oracle.com


Received on Wed Sep 08 1999 - 11:34:49 CDT

Original text of this message

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