DocsReference

Addressing a grid after deleting part of it

Index counts the points that are actually there. Delete some and every point after the gap shifts down, so a field built from Index no longer names the row or column you meant.

The delete's own selection is safe: it runs on the full set of points, where Index still means what you typed. What breaks is anything sampled on the points that survived, most often a per-instance scale or rotation on Instance on Points.

The symptom is misleading. Nothing errors. On a tower with a doorway cut into it, each course lost a few of its columns, so the top ring read as a much lower row than it was, its bricks came out too wide and overlapped their neighbours all the way round. That reads as a problem with closing the ring, and it is not.

Derive the coordinate from position instead, because position survives deletion. For a row, divide the height by the course height and round. The same trick gives you a column on any regular grid.

A scattered cloud has no grid to recover a coordinate from, so this workaround does not exist there. On a scatter, do the deleting after you have finished addressing the points.

Open the editor and try it