Class UpdateGeometrySRID

java.lang.Object
org.h2gis.api.AbstractFunction
org.h2gis.functions.spatial.crs.UpdateGeometrySRID
All Implemented Interfaces:
org.h2gis.api.Function, org.h2gis.api.ScalarFunction

public class UpdateGeometrySRID extends org.h2gis.api.AbstractFunction implements org.h2gis.api.ScalarFunction
Function to update the SRID of a geometry column
Author:
Erwan Bocher, CNRS (2020)
  • Constructor Details

    • UpdateGeometrySRID

      public UpdateGeometrySRID()
  • Method Details

    • getJavaStaticMethod

      public String getJavaStaticMethod()
      Specified by:
      getJavaStaticMethod in interface org.h2gis.api.ScalarFunction
    • changeSRID

      public static boolean changeSRID(Connection connection, String table_name, String column_name, int srid) throws SQLException
      Method to update the SRID
      Parameters:
      connection - active connection to the database
      table_name - name of the tabe
      column_name - name of the geomtry column
      srid - value of the new srid
      Returns:
      true if the SRID is changed
      Throws:
      SQLException
    • changeSRID

      public static boolean changeSRID(Connection connection, String schema_name, String table_name, String column_name, int srid) throws SQLException
      Method to update the SRID
      Parameters:
      connection - active connection to the database
      schema_name - name of the schema
      table_name - name of the tabe
      column_name - name of the geomtry column
      srid - value of the new srid
      Returns:
      true if the SRID is changed
      Throws:
      SQLException
    • changeSRID

      public static boolean changeSRID(Connection connection, String catalog_name, String schema_name, String table_name, String column_name, int srid) throws SQLException
      Method to update the SRID
      Parameters:
      connection - active connection to the database
      catalog_name - name of the catalog
      schema_name - name of the schema
      table_name - name of the tabe
      column_name - name of the geomtry column
      srid - value of the new srid
      Returns:
      true if the SRID is changed
      Throws:
      SQLException