Skip to main content
added 144 characters in body
Source Link
User1974
  • 1.3k
  • 16
  • 64

I know this question is ancient, but for anyone else wondering about this scenario:

Maybe the steps would be:

  1. In a query, validate the polygons using sdo_geom.validate_geometry_with_context().
  2. For the polygons that have problems, use the rectify_geometry() function to fix them (within a query).
  3. Store all the polygons (including the rectified polygons) in the final Oracle table as SDO_GEOMETRY.

That's just a guess. I'm not an Oracle Spatial expert.

I know the question asked for a Java optionsolution, and this proposed solution isn't Java. But maybe it's possible to put the data in a temporary db table somewhere, run the SQL queries on it as I suggested, and then INSERT the resulting data into the final table. Maybe it's possible to run those SQL queries from Java code? (execute SQL from within Java)

Or maybe there is a way to use some sort of Oracle DB tool to load the CSV into a temporary table, and then proceed from there?

Or maybe just use a GIS tool like ArcGIS Pro to import the CSV into a temporary Oracle/SDO_GEOMETRY table. Maybe ArcGIS Pro would automatically rectify any problem polygons. Now that I think about it more, I think I like this idea best. Rectifying and loading GIS data is what GIS tools like ArcGIS Pro are good at.

Just some uneducated thoughts.

I know this question is ancient, but for anyone else wondering about this scenario:

Maybe the steps would be:

  1. In a query, validate the polygons using sdo_geom.validate_geometry_with_context().
  2. For the polygons that have problems, use the rectify_geometry() function to fix them (within a query).
  3. Store all the polygons (including the rectified polygons) in the final Oracle table as SDO_GEOMETRY.

That's just a guess. I'm not an Oracle Spatial expert.

I know the question asked for a Java option, and this proposed solution isn't Java. But maybe it's possible to put the data in a temporary db table somewhere, run the SQL queries on it as I suggested, and then INSERT the resulting data into the final table. Maybe it's possible to run those SQL queries from Java code? (execute SQL from within Java)

Or maybe there is a way to use some sort of Oracle DB tool to load the CSV into a temporary table, and then proceed from there?

Or maybe just use a GIS tool like ArcGIS Pro to import the CSV into a temporary Oracle/SDO_GEOMETRY table. Maybe ArcGIS Pro would automatically rectify any problem polygons.

Just some uneducated thoughts.

I know this question is ancient, but for anyone else wondering about this scenario:

Maybe the steps would be:

  1. In a query, validate the polygons using sdo_geom.validate_geometry_with_context().
  2. For the polygons that have problems, use the rectify_geometry() function to fix them (within a query).
  3. Store all the polygons (including the rectified polygons) in the final Oracle table as SDO_GEOMETRY.

That's just a guess. I'm not an Oracle Spatial expert.

I know the question asked for a Java solution, and this proposed solution isn't Java. But maybe it's possible to put the data in a temporary db table somewhere, run the SQL queries on it as I suggested, and then INSERT the resulting data into the final table. Maybe it's possible to run those SQL queries from Java code? (execute SQL from within Java)

Or maybe there is a way to use some sort of Oracle DB tool to load the CSV into a temporary table, and then proceed from there?

Or maybe just use a GIS tool like ArcGIS Pro to import the CSV into a temporary Oracle/SDO_GEOMETRY table. Maybe ArcGIS Pro would automatically rectify any problem polygons. Now that I think about it more, I think I like this idea best. Rectifying and loading GIS data is what GIS tools like ArcGIS Pro are good at.

Just some uneducated thoughts.

added 131 characters in body
Source Link
User1974
  • 1.3k
  • 16
  • 64

I know this question is ancient, but for anyone else wondering about this scenario:

Maybe the steps would be:

  1. In a query, validate the polygons using sdo_geom.validate_geometry_with_context().
  2. For the polygons that have problems, use the rectify_geometry() function to fix them (within a query).
  3. Store all the polygons (including the rectified polygons) in the final Oracle table as SDO_GEOMETRY.

That's just a guess. I'm not an Oracle Spatial expert.

I know the question asked for a Java option, and this proposed solution isn't Java. But maybe it's possible to put the data in a temporary db table somewhere, run the SQL queries on it as I suggested, and then INSERT the resulting data into the final table. Maybe it's possible to run those SQL queries from Java code? (execute SQL from within Java)

Or maybe there is a way to use some sort of Oracle DB tool to load the CSV into a temporary table, and then proceed from there?

Or maybe just use a GIS tool like ArcGIS Pro to import the CSV into a temporary Oracle/SDO_GEOMETRY table. Maybe ArcGIS Pro would automatically rectify any problem polygons.

Just some uneducated thoughts.

I know this question is ancient, but for anyone else wondering about this scenario:

Maybe the steps would be:

  1. In a query, validate the polygons using sdo_geom.validate_geometry_with_context().
  2. For the polygons that have problems, use the rectify_geometry() function to fix them (within a query).
  3. Store all the polygons (including the rectified polygons) in the final Oracle table as SDO_GEOMETRY.

That's just a guess. I'm not an Oracle Spatial expert.

I know the question asked for a Java option, and this proposed solution isn't Java. But maybe it's possible to put the data in a temporary db table somewhere, run the SQL queries on it as I suggested, and then INSERT the resulting data into the final table. Maybe it's possible to run those SQL queries from Java code? (execute SQL from within Java)

Just some uneducated thoughts.

I know this question is ancient, but for anyone else wondering about this scenario:

Maybe the steps would be:

  1. In a query, validate the polygons using sdo_geom.validate_geometry_with_context().
  2. For the polygons that have problems, use the rectify_geometry() function to fix them (within a query).
  3. Store all the polygons (including the rectified polygons) in the final Oracle table as SDO_GEOMETRY.

That's just a guess. I'm not an Oracle Spatial expert.

I know the question asked for a Java option, and this proposed solution isn't Java. But maybe it's possible to put the data in a temporary db table somewhere, run the SQL queries on it as I suggested, and then INSERT the resulting data into the final table. Maybe it's possible to run those SQL queries from Java code? (execute SQL from within Java)

Or maybe there is a way to use some sort of Oracle DB tool to load the CSV into a temporary table, and then proceed from there?

Or maybe just use a GIS tool like ArcGIS Pro to import the CSV into a temporary Oracle/SDO_GEOMETRY table. Maybe ArcGIS Pro would automatically rectify any problem polygons.

Just some uneducated thoughts.

Source Link
User1974
  • 1.3k
  • 16
  • 64

I know this question is ancient, but for anyone else wondering about this scenario:

Maybe the steps would be:

  1. In a query, validate the polygons using sdo_geom.validate_geometry_with_context().
  2. For the polygons that have problems, use the rectify_geometry() function to fix them (within a query).
  3. Store all the polygons (including the rectified polygons) in the final Oracle table as SDO_GEOMETRY.

That's just a guess. I'm not an Oracle Spatial expert.

I know the question asked for a Java option, and this proposed solution isn't Java. But maybe it's possible to put the data in a temporary db table somewhere, run the SQL queries on it as I suggested, and then INSERT the resulting data into the final table. Maybe it's possible to run those SQL queries from Java code? (execute SQL from within Java)

Just some uneducated thoughts.