Welcome, Guest
Username: Password: Remember me

TOPIC: Point array must contain 0 or >1 elements

Point array must contain 0 or >1 elements 12 years 2 months ago #2622

  • craigm
  • craigm's Avatar
  • Offline
Hi Matt,

I got the error message "Point array must contain 0 or >1 elements" when trying to export a map to shapefile. The shapefile does not get created. It seems to be project specific, as I just tried an export from another project and have no issues.

Thanks,
Craig
The administrator has disabled public write access.

Point array must contain 0 or >1 elements 12 years 2 months ago #2623

  • Matt
  • Matt's Avatar
  • Offline
Hi Craig,
Any chance you could share the workspace that gives you this error, by uploading the .rmdb file to a service such as Google Drive and sending the link through to This email address is being protected from spambots. You need JavaScript enabled to view it. ?

Sounds like a path or polygon with a single point is causing an issue somehow, so it would be interesting to see how this is getting through.

thanks,
Matt
The administrator has disabled public write access.

Point array must contain 0 or >1 elements 12 years 2 months ago #2659

  • craigm
  • craigm's Avatar
  • Offline
Will do.
The administrator has disabled public write access.

Point array must contain 0 or >1 elements 12 years 2 months ago #2708

  • craigm
  • craigm's Avatar
  • Offline
Sent you a link Matt.
The administrator has disabled public write access.

Point array must contain 0 or >1 elements 12 years 2 months ago #2712

  • Matt
  • Matt's Avatar
  • Offline
Hi Craig,
Thanks for the file.
The problem is that there are a couple of islands in your user map with < 2 points, and this is causing an exception when we try to export them as polygons in a Shapefile. We really should protect against this, and I will make sure that a fix for this is included in the next maintenance release.

In the mean time, the workaround is to ensure that these islands are removed from your user map before the export is attempted. The easiest way to do this is probably to remove all islands and shorelines from your user map, delete the rogue islands from the map boundaries in the original map project, regenerate the project and add just the shorelines from the project back into your original user map. This means you can keep all the rest of your edits in the map (isobaths and so forth).

Matt
Last Edit: 12 years 2 months ago by Matt.
The administrator has disabled public write access.

Point array must contain 0 or >1 elements 12 years 2 months ago #2716

  • craigm
  • craigm's Avatar
  • Offline
Thanks Matt,

Deleting the bad "islands" fixed the problem. Good thing to remember in the future.

Craig
The administrator has disabled public write access.

Point array must contain 0 or >1 elements 12 years 2 months ago #2722

  • gpiverson
  • gpiverson's Avatar
  • Offline
In general, it's a good idea to clean those out. There are a lot of GIS applications that don't know how to handle them. Even null area geometries where it has the proper amount of points can be a problem with some applications.

One specific instance that I remember was a GIS application deleting my NULL area polygon part and then extending the previous polygon part with an unclosed line to the 0, 0 origin. In short, they removed the polygon part but didn't modify the point table which had some interesting results when using said geometries.
The administrator has disabled public write access.
SCROLL TO TOP