Clip a layer by another layer by specific attributes

285
3
05-27-2021 08:16 AM
Labels (1)
smay_gis
New Contributor II

I feel like my question is best explained with an example:smay_gis_0-1622128291970.png

I have my bottom hole layer that has been buffered by a specific attribute (Lateral Length) and I have my wellbore trajectory layer. I am wanting to clip my wellbore trajectory layer by the buffer that is related to it. So each bottom hole is related to a trajectory. I am wanting to individually buffer the trajectories. Right now it is clumping all of the buffered holes together so on the right side of the photo those trajectories will not be buffered correctly. Any ideas? Thank you!

0 Kudos
3 Replies
curtvprice
MVP Esteemed Contributor

Assuming the points (buffers) and red lines all share a well ID, you can process these one at a time. This could be done in ModelBuilder using an iterator, on each run  you would select layer by attribute to pick each line and its buffer in turn and clip. Name the clip outputs uniquely with the well-ID or %n% and then append them at the end after the iterator is done (ie outside the iterating model). This would take a while if you have thousands of points.

Hope this helps you out!

0 Kudos
smay_gis
New Contributor II

@curtvprice Thank you for the speedy response! It is a ton of points, so I was fearing that would be the case :(

0 Kudos
curtvprice
MVP Esteemed Contributor

To speed things up for many wells there are two approaches you may want to consider:

1. Make use of the memory workspace - this avoids the slowdown of disk IO

2. If you have a maximum buffer size (or maybe select to groups so you have a group of smaller buffers) you can do the clip in non-overlapping groups. I wrote a tool in the NAWQA toolbox that weeds points years ago to do this (similar problem as yours calculating land use around thousands of wells).

0 Kudos