Shapefile in a file geodatabase??

710
8
Jump to solution
03-07-2019 06:31 PM
deleted-user-7SLqM7dlvYNN
New Contributor III

In Pro 2.3 (and 2.3.1) using the Copy Features geoprocessing tool and after electing to place the output in a File Geodatabase it's insisting on adding '.shp' to the end of the file. I then tried removing the .shp from the output file name but it automatically adds it once Run is clicked.

From the Python window it also fails, as despite not including '.shp' on the output parameter it's tried to add it, when looking at the result:

arcpy.management.CopyFeatures("Structure", r"C:\Temp\Matai\MMPK\Data.gdb\Structures", None, None, None, None)
<Result 'C:\\Temp\\Matai\\MMPK\\Data.gdb\\Structures.shp'>

Using the tool to create shapefiles (outside of a file geodatabase) works fine.

0 Kudos
1 Solution

Accepted Solutions
deleted-user-7SLqM7dlvYNN
New Contributor III

Solution and one final quirk:

After many upgrades and downgrades of Pro I was on Pro 2.3.1 with Data Interop 2.2 installed, as I hadn't yet upgraded to 2.3 of Data Interop. Once I removed Data Interop most of the oddities went away and Pro was again recognizing file geodatabases properly.

There's still one case where it isn't recognizing a file geodatabase which is if I drag a file geodatabase from the Catalog Pane to say the Output Feature Class input box. It automatically changes the output to be a .shp. The default FC in the default Project FGDB is fine, if I manually copy/enter the path to write a new FC in a known FGDB it works fine and if I browse to a FGDB and enter a FC name it's also fine.

Default:

FGDB dragged from Catalog Pane:

View solution in original post

8 Replies
DanPatterson_Retired
MVP Esteemed Contributor

Try

Feature Class to Feature Class—Conversion toolbox | ArcGIS Desktop 

Then try copying to a folder (with the *.shp)

And you are sure that the Data.gdb is actually a geodatabase and not a folder with a *.gdb extension (use File Explorer in windows to confirm, you will know the difference I suspect

JoshuaBixby
MVP Esteemed Contributor

I am running Pro 2.3, and my Copy Features dialog box is missing the bottom box in the dialog.

I don't know if that is related to your issue or not, but I don't have any problems copying features into FGDBs using Copy Features.

0 Kudos
DanPatterson_Retired
MVP Esteemed Contributor

well confirmed

You can fake Arc*, it recognizes a fake gdb and automatically adds *.shp to the output

PS not 3rd line either

KoryKramer
Community Moderator

That's what my thinking was too, Dan.  Mark Peacey‌ is your Data.gdb actually a file geodatabase or just a Windows folder called Data.gdb?

0 Kudos
deleted-user-7SLqM7dlvYNN
New Contributor III

It was a file geodatabase created by ArcGIS Pro. I've tried with a new one in both Pro (2.3.1) and Arc 10.6.1 and get the same result. 

I suspect it's some obscure IT security policy that's been implemented as I've noticed there are some peculiar things happening with any file formats which are made up of multiple files e.g. fgdb's and shapefiles when I use ArcGIS Pro. If I copy and paste a  shapefile in ArcGIS Pro it only copies and renames the .shp and .shp.xml files making it corrupt. If I rename a .shp same thing, only the .shp and .shp.xml files are renamed. All seems to work fine in Arc 10.6.1.

I'll follow up with our network security/IT teams and see what I can find out.

DrewFlater
Esri Contributor

Just for the few people who commented about a third text box on the tool - this is the hovertip that displays when you hover on the path in the Output Feature Class.

JoshuaBixby
MVP Esteemed Contributor

ah, thanks for that clarification.  I was wondering about it.

0 Kudos
deleted-user-7SLqM7dlvYNN
New Contributor III

Solution and one final quirk:

After many upgrades and downgrades of Pro I was on Pro 2.3.1 with Data Interop 2.2 installed, as I hadn't yet upgraded to 2.3 of Data Interop. Once I removed Data Interop most of the oddities went away and Pro was again recognizing file geodatabases properly.

There's still one case where it isn't recognizing a file geodatabase which is if I drag a file geodatabase from the Catalog Pane to say the Output Feature Class input box. It automatically changes the output to be a .shp. The default FC in the default Project FGDB is fine, if I manually copy/enter the path to write a new FC in a known FGDB it works fine and if I browse to a FGDB and enter a FC name it's also fine.

Default:

FGDB dragged from Catalog Pane:

View solution in original post