Skip to main content
Solved

How do I join a CSV to an Esri feature class in an oracle dB and write out the matched records to a feature class in a file geodatabase on my local machine?


kmc5678
Contributor
Forum|alt.badge.img+2

I'm currently using a CSV reader, Database Joiner and ESRI Geodatabase Writer. The join is working perfectly: Screenshot 2023-05-24 141658 

But when I connect the joined output to the geodatabase writer no records are written to the feature class in the file gdb and I get an error saying "Cannot write a non-area feature to an area feature class": Screenshot 2023-05-24 152920I have tried both Drop and Create and Truncate Existing for Table Handling.  

Screenshot 2023-05-24 153145Any suggestions are greatly appreciated.

Best answer by hkingsbury

kmc5678 wrote:

Sorry for the confusion, Yes I'd like the output to be spatial. The dataset I'm joining the CSV to is a polygonal feature class in an oracle enterprise database. I want to join the matching record's attributes of the CSV to an existing buildings dataset and export to a file geodatabase on my local machine.

Is the geometry coming through encoded in an attribute? If it is, you'll need to use a geometryreplacer to turn it spatial.

 

If its not coming through at all with the databasejoiner, you might need to look at using an oracle reader and join the data with a featuremerger or featurejoiner

View original
Did this help you find an answer to your question?

6 replies

hkingsbury
Celebrity
Forum|alt.badge.img+54
  • Celebrity
  • May 24, 2023

You're trying to write non spatial features to a spatial (polygon) layer.

You'll need to change the Geometry in your writer to "Table"


kmc5678
Contributor
Forum|alt.badge.img+2
  • Author
  • Contributor
  • May 24, 2023

Thanks for your response hkingsbury. Changing to "Table" creates a fgdb table. How do I create a feature class?


hkingsbury
Celebrity
Forum|alt.badge.img+54
  • Celebrity
  • May 24, 2023
kmc5678 wrote:

Thanks for your response hkingsbury. Changing to "Table" creates a fgdb table. How do I create a feature class?

A table is a type of feature class. Are you expecting the data to be spatial? In its current form there is no geometry on the feature to make it spatial


kmc5678
Contributor
Forum|alt.badge.img+2
  • Author
  • Contributor
  • May 24, 2023

Sorry for the confusion, Yes I'd like the output to be spatial. The dataset I'm joining the CSV to is a polygonal feature class in an oracle enterprise database. I want to join the matching record's attributes of the CSV to an existing buildings dataset and export to a file geodatabase on my local machine.


hkingsbury
Celebrity
Forum|alt.badge.img+54
  • Celebrity
  • Best Answer
  • May 24, 2023
kmc5678 wrote:

Sorry for the confusion, Yes I'd like the output to be spatial. The dataset I'm joining the CSV to is a polygonal feature class in an oracle enterprise database. I want to join the matching record's attributes of the CSV to an existing buildings dataset and export to a file geodatabase on my local machine.

Is the geometry coming through encoded in an attribute? If it is, you'll need to use a geometryreplacer to turn it spatial.

 

If its not coming through at all with the databasejoiner, you might need to look at using an oracle reader and join the data with a featuremerger or featurejoiner


kmc5678
Contributor
Forum|alt.badge.img+2
  • Author
  • Contributor
  • May 24, 2023

This was the issue! The geometry wasn't coming through with databasejoiner. I used an oracle spatial reader and fed both datasets into Featurejoiner and was able to write out a polygonal feature class! Thanks so much hkingsbury I really appreciate the help.


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings