Select to view content in your preferred language

Export from ArcGIS Pro to .csv - Need to include the object_id values

943
7
04-01-2024 05:30 AM
MillieBuckner
Emerging Contributor

Is there  a way to include the object_id field when exporting from arcGIS to a .csv file?

0 Kudos
7 Replies
George_Thompson
Esri Notable Contributor

Is the data you are exporting part of the geodatabase or just a table in the database?

When you add the table to a map does it ask for you to "assign" an ObjectID (in a pop up window)?

--- George T.
0 Kudos
MillieBuckner
Emerging Contributor

 

Is the data you are exporting part of the geodatabase or just a table in the database?

MillieBuckner_0-1711976678156.png

 

 

When you add the table to a map does it ask for you to "assign" an ObjectID (in a pop up window)?

Answer:  yes, the map asked for the field(s) that would serve as the unique id.  

0 Kudos
MillieBuckner
Emerging Contributor

George,

I am putting a series of screenshots together showing the whole sequence the leads to the loss of the id field. I think I can include a solution.  It strikes me as an behavior, so I am wondering if I am creating a problem by making a misstep is how I am working with the product and my data.

 

 

0 Kudos
George_Thompson
Esri Notable Contributor

Thanks for the info above. I think the issue is that when you add a table not registered with the geodatabase, and you have Pro (ArcGIS) create an ObjectID, it is NOT a field in the table. Pro will create a "virtual" ObjectID field and use that in the client.

Does the source table have an ObjectID field that matches what you see in Pro in Oracle (look using sqlplus)?

If the field does not exist in the Oracle table, then it would not be exported from Pro.

--- George T.
0 Kudos
MillieBuckner
Emerging Contributor

Problem appears when id field is not available for export.  why?  You have to look at the last image to see it

 

Table from oracle database being added to map through dbConnection

MillieBuckner_0-1711981157613.png

 

Data just added to arcgis from an oracle table

MillieBuckner_2-1711981272013.png

 

 

Geocoding the addresses

MillieBuckner_3-1711981308845.png

MillieBuckner_4-1711981348258.png

 

MillieBuckner_5-1711981391159.png

 

MillieBuckner_6-1711981452458.png

 

Export geocoding

MillieBuckner_7-1711981496258.png

 

Picking a folder not in project for saving exported data

MillieBuckner_8-1711981541150.png

MillieBuckner_9-1711981735667.png

MillieBuckner_10-1711981765477.png

 

 

 

0 Kudos
George_Thompson
Esri Notable Contributor

Ok, so it looks like you are exporting the "new" geocoded table. When you geocode a table it creates a new feature class (table).

Not sure why those fields are missing.

--- George T.
0 Kudos
MillieBuckner
Emerging Contributor

There is a different problem upstream from the export of the geo-coded addresses.   arcgis keeps failing when looking at oracle data, because oracle is giving arcgis old data.  Here are the steps

1.  Make table 001

2.  update table 001

3.  add table 001 to arcgis pro.

4.  The data visible in arcgis is the data that was in the table on step 1, not step 2

 

To get around this, I have to make table 002 from table 001 after it has been updated, and show arcgis table 002.

Something is wrong with our oracle installation.

0 Kudos