Select to view content in your preferred language

How to batch edit Z values and set them all to zero.

1076
11
Jump to solution
01-28-2025 07:56 AM
AaronManuel2
Regular Contributor

Hi, I have a line feature class with about 80k rows. It is z-enabled and some of the z values are causing extent errors, or at least I think thats whats happening. I have some vertices with a z value of 300k when they obviously shouldnt be anything near that. I'd like to edit the z-value for all vertices in this feature to 0, which is already the default value defined in our web service.

I am aware of the Adjust 3D Z tool but the problem is this tool only lets you set a relative value instead of an absolute value. If I use this tool than I can fix the vertices that have bad Zs, but the features which already have a value of 0 will be wrong. I also dont see a way to batch select vertices given a certain z value.

The other option is I can export the current record set, and disable Zs which will set them to 0. Then delete what we have in our db, and append the rows back with the 'fixed' Zs. 

Is there really no better way to do this with gp tools or arcpy? Any other solutions? Thank you.

 

11 Replies
Bud
by
Esteemed Contributor

The other option is I can export the current record set, and disable Zs which will set them to 0. Then delete what we have in our db, and append the rows back with the 'fixed' Zs. 

Instead of deleting the existing features and replacing them with new features, you could update the existing features using the new-ish upsert functionality in the Append tool. GP tool to batch-replace geometries from one FC to another (via related IDs)

Bud
by
Esteemed Contributor

Could Calculate Geometry or Calculate Geometry Attributes be used to update Z-values?

Here's an article that pertains to M values, which are similar to Z values: Maintain Measure Attributes

Edit: I suspect no.

0 Kudos