Select to view content in your preferred language

ArcGIS Pro won't export unique identifier of SQL View table to gdb table

896
11
Jump to solution
04-02-2025 10:33 AM
Labels (2)
AndreaB_
Frequent Contributor

Hello all,

I found my question asked here on gis stack exchange https://gis.stackexchange.com/questions/458196/arcgis-pro-wont-export-unique-identifier-of-view-tabl... but I am not on the gis stack exchange so I wanted to bring it to the Esri community. I am having the same problem as the poster there - I have a SQL view with a unique identifier. When I export the view to a table in a geodatabase the unique identifier does not export. In the Fields view it sees it as data type "Object ID". I'm using Pro 3.2.4 and I also tried it in 3.1.5. 

Assuming this is a bug?

I tried the workaround suggested by the one answer: "creating a new table in the GDB with an imported schema matching the SQL table, then appended the SQL table records to the new table." But all I got was a field with 0s in it.

Does anyone have a way to get this to work?

Thank you!

0 Kudos
11 Replies
AndreaB_
Frequent Contributor

ah, very interesting! From your link, I learned I can Edit Query Layer and pick a different unique identifier field, although it doesn't do me any good in this scenario because the only field I can use is the one Pro picked for me. 

I'll try to remember in the future to only reference the SQL view table itself in the tools and not the layer in the map.

Thanks for the added info!

SSWoodward
Esri Contributor

If the origin table has an OID or some other unique id, including it in the view as well so it gets picked up when the layer is created may also be a solution.

Glad to help 🙂