Skip to main content

How can I define a simple Oracle spacial reader and writer containing some Oracle SDO_GEOMETRY fields. The fields are not shown among the other attributes. I just want to copy them, no conversion etc.

Perhaps this will help? You can select the oracle_type in the reader and the writer under Format Attributes


Perhaps this will help? You can select the oracle_type in the reader and the writer under Format Attributes

Thanks a lot Lars, but how do I know which Format Attribute to select (oracle_type?) and how do I map it to the name of the column in the database?

 

 


@fritspoulsen12 It sounds like you have an Oracle table with multiple spatial columns. This is not handled through attributes. You have to set the geometry name - with is a property of the FME geometry. We have a tutorial that covers working with multiple spatial columns on the KnowledgeCentre: Handling Data that contains Multiple Geometry columns. FME can't create the table with multiple spatial columns, you'll have to do this using SQLExecutor or your favorite database management application.

If you only one spatial column, FME should handle this fine. You'll just need to set the spatial column name on the FME Feature Type.


@MarkAtSafe @lars_de_vries Thanks guys. I actually only have one spatial column in the Oracle table. As I understand you, I should expose the "oracle_type" in the Format Attributes for the reader or writer. But how do I tell FME which of the columns in the table is the spatial column? Is that automatically the one which is not a User Attribute?


By the way - when I select a Spatial Reader, the view with the spacial column is not shown in the dataset list. But when selecting a Non-spacial reader, the view appears in the dataset list.

It really puzzles me, that it should be so difficult to copy a colunm of SDO_GEOMETRY type from one table to another.

Any help would be much appreciated.


If you only have one spatial column then the default settings in FME should handle it. You can change the name of the spatial column as shown below.


@MarkAtSafe Thanks Mark. Unfortunately I can't redo, what you're suggesting. I'm not sure what kind of Reader and Writer to select to get the same result. I don't have something like "Oracle op-12c[Oracle Spatial] - 2 to select for the writer.

And should I enter the actual colunm name from the in- and output table to tell FME which columnname is the SDO_GEOMETRY type column. Still the SDO columns aren't visible in the reader or writer, attributes, so how do I map them to each other to get them copied from reader to writer?

This is a major problem for us, since we have a lot of tables with just one SDO_GEOMETRY type column the we want to copy along with normal field types.

So any help is much appreciated, Maybe even a simple .FMW file showing how to do it.


Reply