I ran a geocode and it created several points that have null geometry. They don't show up on the map, so I cannot place them manually.
Solved! Go to Solution.
Just updating the geometry of a point turned out to be pretty simple, but took a surprising amount of searching to find.
In this case, I had several points that didn’t geocode (geocode score of zero) that had null geometry and didn’t show up on the map. I was unable to manually place them with the point editing tools, or if there’s a way, it escaped me. I started by selecting the features I wanted to place and opening the field calculator on the Shape field. I calculated the “Shape” field to code_block(!Shape!), with a code block of:
def code_block(shape):
point = shape.getPart(0)
point.X = -125
point.Y = 46.2
return point
This just placed the 4 selected points out in the ocean at that location, just so I had some valid point geometry, and then I moved them by hand to the correct location I determined.
If you know the location's x/y, then you could do something more elegant, one point at a time.
Esri doc (search for “shift”): https://pro.arcgis.com/en/pro-app/2.8/tool-reference/data-management/calculate-field-examples.htm
NOTE: I took this screenshot a long time ago, back when GP tools just worked on the selected set. Now, there will be a toggle to indicate you are only working on a subset of the data.
If you have a null geometry point feature selected in the Attribute Table, are you able to use the Replace Geometry tool to click on a location in the map?
I tested this just now by creating a new point via the Attribute Table (no geometry provided). I selected the point in the attribute table, activated the Replace Geometry tool (it's one of the standard editing tools in the 'Modify Features' menu or 'Tools' gallery in the Edit ribbon menu), and I was able to click anywhere in the map to give it that point geometry.
Just updating the geometry of a point turned out to be pretty simple, but took a surprising amount of searching to find.
In this case, I had several points that didn’t geocode (geocode score of zero) that had null geometry and didn’t show up on the map. I was unable to manually place them with the point editing tools, or if there’s a way, it escaped me. I started by selecting the features I wanted to place and opening the field calculator on the Shape field. I calculated the “Shape” field to code_block(!Shape!), with a code block of:
def code_block(shape):
point = shape.getPart(0)
point.X = -125
point.Y = 46.2
return point
This just placed the 4 selected points out in the ocean at that location, just so I had some valid point geometry, and then I moved them by hand to the correct location I determined.
If you know the location's x/y, then you could do something more elegant, one point at a time.
Esri doc (search for “shift”): https://pro.arcgis.com/en/pro-app/2.8/tool-reference/data-management/calculate-field-examples.htm
NOTE: I took this screenshot a long time ago, back when GP tools just worked on the selected set. Now, there will be a toggle to indicate you are only working on a subset of the data.
If you have a null geometry point feature selected in the Attribute Table, are you able to use the Replace Geometry tool to click on a location in the map?
I tested this just now by creating a new point via the Attribute Table (no geometry provided). I selected the point in the attribute table, activated the Replace Geometry tool (it's one of the standard editing tools in the 'Modify Features' menu or 'Tools' gallery in the Edit ribbon menu), and I was able to click anywhere in the map to give it that point geometry.
Good solution. I searched for something like this and didn't find it, which is what led me to the solution I posted. I've worked with Esri software my whole career and seen lots of points placed at Null Island (0, 0), but only rarely get null geometry. I honestly don't know why the Shape field isn't required. It makes no sense to have a point layer with missing geometry, but that's going off on a tangent.