Go to content Go to navigation and search

Home

Free Software Download

Download Code, Packages and Installers

Object Documentation

Package Documentation

CENTROID
COGO
EXPORTER
GEOM
KML
NETWORK
SDO_ERROR
Spatial Companion For Oracle (SC4O)
TOOLS

Articles

    New versions of LINEAR, CENTROID and GEOM etc packages
    TESSELATE and CENTROID package updates
    Applying and Extending Oracle Spatial: Source Code Problem
    CENTROID package use with ESRI's sde.st_geometry
    Changes to CENTROID and TESSELATE packages
    CENTROID Package now returns centroid of multi-linestring
    New versions of PL/SQL packages uploaded
    New Release of Free PL/SQL Packages
    New version of PL/SQL packages released
    New Version PL/SQL Spatial packages released
    New PL/SQL Package Upload
    PL/SQL Spatial Types and Packages
    Update to PL/SQL Packages
    New PL/SQL Packages
    VB6 Oracle Spatial or Locator OO4O code
    Spatial PL/SQL Packages by Example
    Catalog Registry Tool
    Image Catalog Tool
    Oracle Spatial PL/SQL and VB6 Source Code


Search

Browse

RSS / Atom

Email me

textpattern

Creative Commons License
All Blog Articles, Data Models and Free Source Code by Simon Greener, The SpatialDB Advisor is licensed under a Creative Commons Attribution-ShareAlike 3.0 Unported License.

NETWORK

Monday August 15 2011 at 07:16

Here’s a package with a few functions for getting the start/end point of an sdo_geometry.

This package should be dropped and moved in to the LINEAR or GEOM packages.

Until then, here is the header.

DEFINE defaultSchema = '&1'
 
CREATE OR REPLACE PACKAGE Network
AUTHID CURRENT_USER
AS
 
  FUNCTION get_point (p_geometry     IN MDSYS.SDO_GEOMETRY,
                      p_point_number IN NUMBER DEFAULT 1 ) 
    RETURN MDSYS.SDO_GEOMETRY DETERMINISTIC;
 
  FUNCTION get_Start_Point ( p_geometry IN MDSYS.SDO_GEOMETRY ) 
    RETURN MDSYS.SDO_GEOMETRY DETERMINISTIC;
 
  FUNCTION SDO_StartPoint ( p_geometry IN MDSYS.SDO_Geometry )
    RETURN MDSYS.SDO_Geometry DETERMINISTIC;
 
  FUNCTION get_End_Point ( p_geometry IN MDSYS.SDO_GEOMETRY ) 
    RETURN MDSYS.SDO_GEOMETRY DETERMINISTIC;
 
  FUNCTION SDO_EndPoint ( p_geometry IN MDSYS.SDO_Geometry )
    RETURN MDSYS.SDO_Geometry DETERMINISTIC;
 
  FUNCTION get_point_text ( p_geometry     IN MDSYS.SDO_GEOMETRY,
                            p_point_number IN NUMBER DEFAULT 1 ) 
    RETURN VARCHAR2 DETERMINISTIC;
 
  FUNCTION get_Start_point_text ( p_geometry IN MDSYS.SDO_GEOMETRY )
    RETURN VARCHAR2 DETERMINISTIC;
 
  FUNCTION get_End_point_text ( p_geometry IN MDSYS.SDO_GEOMETRY )
    RETURN VARCHAR2 DETERMINISTIC;
 
END Network;

Creative Commons License

post this at del.icio.uspost this at Diggpost this at Technoratipost this at Redditpost this at Farkpost this at Yahoo! my webpost this at Windows Livepost this at Google Bookmarkspost this to Twitter

Comment

META HTTP-EQUIV=