GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • V6.x Documentation
  • Contact
  • Privacy Statement
  • Contributor License Agreement
  • Software License Agreement
  • Trademarks

This view

  • Original page
  • New address

GeezerVison is showing docs.voltdb.com — VALIDPOLYGONFROMTEXT()

  • VoltDB Home
  • Forums
  • V6.x Books
    • VoltDB Tutorial
    • Using VoltDB
    • VoltDB Performance Guide
    • VoltDB Planning Guide
    • VoltDB Administrator's Guide
  • Current docs ▶
VALIDPOLYGONFROMTEXT()

Documentation

VoltDB Home » Documentation » Using VoltDB
< previoustable of contentsnext >

VALIDPOLYGONFROMTEXT()

VALIDPOLYGONFROMTEXT() — Returns a validated GEOGRAPHY value from the corresponding WKT

Synopsis

VALIDPOLYGONFROMTEXT( text )

Description

The VALIDPOLYGONFROMTEXT() function generates a valid GEOGRAPHY value from a string containing a well known text (WKT) representation of a geographic polygon. If the GEOGRAPHY value resulting from the WKT string is not a valid representation of a polygon, the function returns an error. The error message includes an explanation of why the WKT is not valid.

The difference between the POLYGONFROMTEXT() function and the VALIDPOLYGONFROMTEXT() function is that the VALIDPOLYGONFROMTEXT() verifies that the resulting polygon meets all of the requirements for use by VoltDB. If not, the function returns an error. The POLYGONFROMTEXT() function simply constructs a GEOGRAPHY value without validating all of the requirements of a VoltDB polygon and may need separate validation (using the ISVALID() function) before it can be used effectively with other geospatial functions. See the description of the ISVALID() function for a description of the requirements for a valid polygon.

Example

The following example uses the VALIDPOLYGONFROMTEXT() function to insert a record containing a GEOGRAPHY column using a text input value containing the WKT representation of a geographic polygon. Note that if

INSERT INTO city (name, state, boundary) VALUES(?, ?, VALIDPOLYGONFROMTEXT(?));
< previoustable of contentsnext >
You are visitor 01402775 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.