I want to take all shapefiles within a folder, import to a new gdb, and iterate several processes. Including rename, add and calculate fields, then define the projection. I keep running into issues with naming invalid characters. I'm using inline variables %Name% and %ISO 8601% because I want to just add my ISO 8601 variable to the end of the shp's original name. This will put all the shps into the gdb, without renaming them or continuing the model.

When I try to take an individual shp-feature to feature that renames it in the process and puts it in the gdb, it will give me "featureclass_%ISO 8601%" but not add/calculate fields or project.

What am I missing and is there anything else I can make more efficient?

OriginalModel Rename Error FeatureClass_ISO8601

1 Answer 1


A valid file geodatabase feature class must not start with a number, have spaces or unusual characters.

Look at your error message for the rename tool it has appended ".shp" to the end and a "." is invalid. Use the Parse path tool to extract out parts of dataset name so you can construct your output feature class name correctly.

Also your model logic is flawed. EVERYTHING runs the number of times an iterator loops. That includes everything feeding into the iterator, so your create file geodatabase tool will simply overwrite on each loop. You need to put the iterator and all connecting downstream tools into a sub model. Don't know what a sub-model is, read the help file here.

  • That worked after I learned how to use those tools, thank you so much. I've run into a different issue down the line in case anybody else searches this in the future. gis.stackexchange.com/q/469924/232909
    – CarteCraft
    Commented Nov 9, 2023 at 1:59

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.