Geographic Information Systems Stack Exchange is a question and answer site for cartographers, geographers and GIS professionals. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have a ArcGIS feature class of geometry type polygon. It was created as a convex hull with a 200 meter buffer on a point dataset, aggregating rows on a particular field. The number of points used to generate each polygon is variable, starting at 1. I use ogr2ogr to upload from a personal geodatabase (.MDB) to a remote PostGIS database, and MapServer 5.4 to display. All features are uploaded successfully, but those polygon features that were generated from a single point do not plot using MapServer. Based on how the polygons are generated, all those based on a single point ought to be circles with radii of 200 meters.

In the PostGIS table the geometry field is empty for all those features, and following a tip I found here I tried "select st_npoints(wkb_geometry) from merged_dist_areas;" and it appears all the "missing" polygon features have no points at all, which may explain why they do not plot.

What can I do to plot these circles?

share|improve this question

closed as unclear what you're asking by PolyGeo Mar 8 '15 at 23:09

Please clarify your specific problem or add additional details to highlight exactly what you need. As it's currently written, it’s hard to tell exactly what you're asking. See the How to Ask page for help clarifying this question.If this question can be reworded to fit the rules in the help center, please edit the question.

As the answer says "too many unknown here to say anything about where the failure has happened" so to progress this further we would need you to provide precise details of your procedure leading up to where what you observed deviated from what you were expecting. – PolyGeo Mar 8 '15 at 23:08

What you have to do is finding out where in this chain something has gone wrong. As I understand it you did the geoprocessing in ArcGIS? Did you confirm that the 200 meter circles was properly created?

There is too many unknown here to say anything about where the failure has happened.

But if I were you I would just import the original table and do the processing in PostGIS. Then it will also be easier to find what is failing.

In PostGIS it would look something like:

CREATE TABLE new_table as
SELECT ST_Buffer(ST_Convexhull(ST_Collect(the_geom))) as the_geom
from point_table group by group_field;
share|improve this answer
The circles appear to be correctly generated and plotted in ArcGIS. I just tried a new upload by exporting from ArcGIS to a shapefile and uploading using the shapefile loader in PgAdmin, and it appears to work. At least there are points in all the resulting polygon geometries now. Perhaps there is something with the ogr2ogr personal geodatabase driver that's missing. I will check for a new version and report back. Thanks for the processing tip, I will try that next. – user2372 Mar 17 '11 at 15:07
ok, what is the reault of st_astext(the_geom) on the not working geometries. maybe arcgis creates a circle from curves when using buffer on a foint. maybe ogr2ogr just passes this curve to postgis. postgis understand curves but I don't think Mapserver does. shapefile don't handle curves so arcgis converts when exporting to shape. – Nicklas Avén Mar 17 '11 at 16:22
Using ogr2ogr to import from the personal geodatabase the st_astext function returns empty geometries for the non-working features, and all working features are inserted as POLYGON. There are no errors reported by ogr2ogr. Using the shapefile loader all features work, are inserted as MULTIPOLYGON, and the circles all have 101 points. I downloaded the latest version of FWTools and tried the ogr2ogr supplied there and now get an informative error: ERROR 1: INSERT command for new feature failed. ERROR: geometry requires more points. – user2372 Mar 17 '11 at 16:59
Following your hint about curves above, this topic appeared . One sentence may summarize the problem I am experiencing: "No, OGR does not support curves from the personal geodatabase". From what I can determine, ArcGIS does in fact store circles as curves, except in shapefiles. – user2372 Mar 17 '11 at 18:07
ok, then you have found the problem :-) little strange behavior of arcgis to cerate a curve just in the special case when buffering a point and apparently not as part of other buffering. handloing curves will just give you trouble like you just have expåerienced. choose the best way to get rid if them. the export path through shape file or do the processing in PostGIS. – Nicklas Avén Mar 17 '11 at 20:49