0

This is my first time building a model from scratch, so let me know if I've omitted anything in describing this question.

I have a geodatabase that contains shapefiles (polygons) of watersheds. I need to intersect each polygon with a shapefile (polygons) of land use. I can get the following to work, but only for one file at a time.

enter image description here

But I'm not sure I've created a model that will properly loop through all the watersheds in the geodatabase (see below). I used a for loop, but I'm not sure I used it properly. I also need them to be exported as their original name, but in a different geodatabase. Is this how an iterative intersect model would work?

enter image description here

1
  • Simple intersect will do unless your watersheds stored in different feature classes
    – FelixIP
    Commented May 8, 2019 at 6:17

1 Answer 1

2

Assuming you're intersecting the same land use polygon feature class to all watersheds I would try something a bit like this:

enter image description here

The in-line substitution in the output should get the path to your result gdb and create a feature class that inherit the name of the feature class in your input gdb.

1
  • The inline variable substitution should be something unique like "Inter_%Name%" Using "%Name%" may overwrite your input watershed layer. Also, if there are other feature classes in the GDB, try putting "Water" or something unique at the beginning of all the watershed feature classes. That way, when you use Iterate Feature Classes you can add Water* as a wildcard to only include feature classes that start with that word; instead of using all feature classes in a GDB.
    – Smithw1
    Commented Sep 4, 2019 at 17:57

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.