30.3 SDO_SAM.BIN_GEOMETRY
Format
SDO_SAM.BIN_GEOMETRY( geom IN SDO_GEOMETRY, tol IN SDO_DIM_ARRAY, bin_tablename IN VARCHAR2, bin_colname IN VARCHAR2 ) RETURN NUMBER;
or
SDO_SAM.BIN_GEOMETRY( geom IN SDO_GEOMETRY, dim IN SDO_DIM_ARRAY, bin_tablename IN VARCHAR2, bin_colname IN VARCHAR2 ) RETURN NUMBER;
Description
Computes the most-intersecting tile for a geometry.
Parameters
- geom
-
Geometry for which to compute the bin.
- tol
-
Tolerance value (see Tolerance).
- dim
-
Dimensional array for the table that holds the geometries for the bins.
- bin_tablename
-
Name of the table that holds the geometries for the bins.
- bin_colname
-
Column in
bin_tablename
that holds the geometries for the bins.
Usage Notes
This function returns the bin that intersects most with the specified geometry. If multiple bins intersect to the same extent with the specified geometry, the bin with the smallest area is returned.
To perform this operation on all rows in the data mining table, using the specified bin_tablename
, you can use the SDO_SAM.BIN_LAYER procedure.
Examples
The following example computes the bin for a specified geometry.
SELECT sdo_sam.bin_geometry(a.geometry, 0.0000005, 'BINTBL', 'GEOMETRY') FROM poly_4pt a, user_sdo_geom_metadata b WHERE b.table_name='POLY_4PT' AND a.gid=1; SDO_SAM.BIN_GEOMETRY(A.GEOMETRY,0.0000005,'BINTBL','GEOMETRY') -------------------------------------------------------------- 43 1 row selected.
Parent topic: SDO_SAM Package (Spatial Analysis and Mining)