Solved

First time using FME - CAD to GIS Error Deciphering


Badge +7

Hey,

 

<-- I saved the template with source data here

 

I am currently using a trial licence to see if FME is what my organisation is looking for, so please bare with me as I am very new to FME and the terminology.

The first task I am trying to achieve is converting a large CAD document for use in our GIS System (I see this is very common, and I have watched several youtube tutorials and a few Safe videos, so I understand the basic concept).

 

I have created my first Project, it works for 90% of my data, its the last 10% I am stuck and needing advice on.

 

As you can see i have my CAD input on the left, a few filters and the likes, and it outputs to my GIS tables on the right. It is the 'Annotation4_History' that is causing me grief, and I am unable to decipher the error message. I am sure it is telling me what is wrong, I just dont understand how to fix it.

The input parameters on the cad document are (note: used Group By Geometry):

If I disable the writer 'Annotation4_History' the tool runs perfectly with no errors from start to end.

 

You can see I am inputting text type from my CAD file into a tester, it is filtering off layers that containg the characters 'HIST', if this is true data goes into 'Annotation4_History', if all else it goes into 'Annotation4'.

 

Annotation4 is filling just fine, it seems to be the Annotation4_History that is causing issues.

 

I have attached the LOG file containing the error messages, I have also included the workbench for your reference.

 

I am basically wondering if I am doing something silly? Or is there something wrong with my input data?

 

Thanks for your time.

 

icon

Best answer by itay 4 September 2019, 08:03

View original

11 replies

Badge +16

Hi @benvk,

Welcome to the wonderful world of FME and its awesome community!

Congrats on creating this workflow as a start of your FME use.

Tip: when creating a template to upload in the forum save the source data with it so that forum user can help by running the workspace.

Since I cannot run the workspace and see what is taking place with the text features, I can only use the provided log file. According to the error description:

2019-09-04 06:26:11|  33.8|  0.0|ERROR |Cannot write a non-area feature to an area feature class

I would guess that text features with invalid geometry are going into the Annotation4_History feature class.

I suggest you use a GeometryFilter transformer to make sure only the allowed geometry type ends up in the Annotation4_History writer feature type.

Hope this helps,

Itay

Badge +7

Hi @benvk,

Welcome to the wonderful world of FME and its awesome community!

Congrats on creating this workflow as a start of your FME use.

Tip: when creating a template to upload in the forum save the source data with it so that forum user can help by running the workspace.

Since I cannot run the workspace and see what is taking place with the text features, I can only use the provided log file. According to the error description:

2019-09-04 06:26:11|  33.8|  0.0|ERROR |Cannot write a non-area feature to an area feature class

I would guess that text features with invalid geometry are going into the Annotation4_History feature class.

I suggest you use a GeometryFilter transformer to make sure only the allowed geometry type ends up in the Annotation4_History writer feature type.

Hope this helps,

Itay

Hi @itay, thanks for the info! And thanks for the tip about saving source data for uploading, I will look into that process!

Also just clarifying best practice, is there preference as to where this should go? Should this be right before data enters the writing tool? Or right after it leaves the Reader tool?

Badge +16

Hi @itay, thanks for the info! And thanks for the tip about saving source data for uploading, I will look into that process!

Also just clarifying best practice, is there preference as to where this should go? Should this be right before data enters the writing tool? Or right after it leaves the Reader tool?

Hi @benvk, In this scenario (writing to a format restricted to one geometry type per feature class) I would like to know asp if I have the correct geometry types, so after the reader feature type.

From my experience CAD drawings can contain multiple geometry types per layer so it's a matter of best practise to get to know your data before writing it.

Badge +7

Hi @benvk,

Welcome to the wonderful world of FME and its awesome community!

Congrats on creating this workflow as a start of your FME use.

Tip: when creating a template to upload in the forum save the source data with it so that forum user can help by running the workspace.

Since I cannot run the workspace and see what is taking place with the text features, I can only use the provided log file. According to the error description:

2019-09-04 06:26:11|  33.8|  0.0|ERROR |Cannot write a non-area feature to an area feature class

I would guess that text features with invalid geometry are going into the Annotation4_History feature class.

I suggest you use a GeometryFilter transformer to make sure only the allowed geometry type ends up in the Annotation4_History writer feature type.

Hope this helps,

Itay

@itay thanks again. 

Just to clarify my inputs on the left are not layers from within my ACAD document I actually selected the option 'GEOMETRY' when I set the Autodesk AutoCAD DWG/DXF Parameters. 

So the readers that are shown left of screenshot are geometry types that have more than one item within them (the others have been removed for clarity). if I were to use Layer Name as my inputs there would have been an unacceptable amount of inputs to manage. I thought as I was trying to group my outputs to the 4 types (Annotation, Polyline, Point and Polygon) this method would simplify my process. But as I said I am very new and open to suggestions if you think I can do this better.

These are the input parameters I have used (added to my original post too):

0684Q00000ArMbhQAF.jpg

 

Cheers

Badge +16

@itay thanks again. 

Just to clarify my inputs on the left are not layers from within my ACAD document I actually selected the option 'GEOMETRY' when I set the Autodesk AutoCAD DWG/DXF Parameters. 

So the readers that are shown left of screenshot are geometry types that have more than one item within them (the others have been removed for clarity). if I were to use Layer Name as my inputs there would have been an unacceptable amount of inputs to manage. I thought as I was trying to group my outputs to the 4 types (Annotation, Polyline, Point and Polygon) this method would simplify my process. But as I said I am very new and open to suggestions if you think I can do this better.

These are the input parameters I have used (added to my original post too):

0684Q00000ArMbhQAF.jpg

 

Cheers

@benvk, I would do the same to limit the number of reader feature type in the workspace (CAD layers or levels)

Another option is to use the Single Merged Feature Types, that will produce one reader feature type from which all the features are made available.

So I would try to evaluate the text features to see if they contain the geometry type expected by the SDE writer.

When a translation errors usually a FFS file is saved with the erros 

2019-09-04 06:26:12|  33.9|  0.0|STATS |Stored 1 feature(s) to FME feature store file `C:\Users\benva\Desktop\CAD to GDB Live Data_log.ffs'

Sometimes this opening this file (via the Data Inspector) can provide some valuable information.

Badge +7

@benvk, I would do the same to limit the number of reader feature type in the workspace (CAD layers or levels)

Another option is to use the Single Merged Feature Types, that will produce one reader feature type from which all the features are made available.

So I would try to evaluate the text features to see if they contain the geometry type expected by the SDE writer.

When a translation errors usually a FFS file is saved with the erros 

2019-09-04 06:26:12|  33.9|  0.0|STATS |Stored 1 feature(s) to FME feature store file `C:\Users\benva\Desktop\CAD to GDB Live Data_log.ffs'

Sometimes this opening this file (via the Data Inspector) can provide some valuable information.

@itay I have implemented the filter as suggested, and filtered for text:

0684Q00000ArNJaQAN.jpg

 

I then re-ran this section, and once again am getting a fatal error - attached - 201909041657.txt

:(

Badge +16

Hi @benvk,

Welcome to the wonderful world of FME and its awesome community!

Congrats on creating this workflow as a start of your FME use.

Tip: when creating a template to upload in the forum save the source data with it so that forum user can help by running the workspace.

Since I cannot run the workspace and see what is taking place with the text features, I can only use the provided log file. According to the error description:

2019-09-04 06:26:11|  33.8|  0.0|ERROR |Cannot write a non-area feature to an area feature class

I would guess that text features with invalid geometry are going into the Annotation4_History feature class.

I suggest you use a GeometryFilter transformer to make sure only the allowed geometry type ends up in the Annotation4_History writer feature type.

Hope this helps,

Itay

I see that all the features have point geometry, so the GeometryFilter transformer is not necessary anymore.

Have you tried setting a different value to the writer parameter: transaction type ?(http://docs.safe.com/fme/2019.1/html/FME_Desktop_Documentation/FME_ReadersWriters/geodatabase/GEODATABASE_SDE_writer.htm)

Badge +7

I see that all the features have point geometry, so the GeometryFilter transformer is not necessary anymore.

Have you tried setting a different value to the writer parameter: transaction type ?(http://docs.safe.com/fme/2019.1/html/FME_Desktop_Documentation/FME_ReadersWriters/geodatabase/GEODATABASE_SDE_writer.htm)

That last run that I did (with the latest error log) I had just run the TEXT reader through to the annotation writers (x2), so they may be appearing as point type, the ACAD file that I am converting from also contains lines, arcs, hatches etc...

Also as I am new to this I do not entirely understand what you mean when you suggested setting a different value to the writer parameter: transaction type? I have very much accepted defaults for most things to get off the ground. Could you please let me know what you suggest I change from/to?

Sorry for being so daft.

Badge +16

Hi @benvk,

Welcome to the wonderful world of FME and its awesome community!

Congrats on creating this workflow as a start of your FME use.

Tip: when creating a template to upload in the forum save the source data with it so that forum user can help by running the workspace.

Since I cannot run the workspace and see what is taking place with the text features, I can only use the provided log file. According to the error description:

2019-09-04 06:26:11|  33.8|  0.0|ERROR |Cannot write a non-area feature to an area feature class

I would guess that text features with invalid geometry are going into the Annotation4_History feature class.

I suggest you use a GeometryFilter transformer to make sure only the allowed geometry type ends up in the Annotation4_History writer feature type.

Hope this helps,

Itay

It's a setting in the writer parameters:

0684Q00000ArMbsQAF.png

and the correct setting depends on the SDE setup.

Badge +16

That last run that I did (with the latest error log) I had just run the TEXT reader through to the annotation writers (x2), so they may be appearing as point type, the ACAD file that I am converting from also contains lines, arcs, hatches etc...

0684Q00000ArN4zQAF.png

Also as I am new to this I do not entirely understand what you mean when you suggested setting a different value to the writer parameter: transaction type? I have very much accepted defaults for most things to get off the ground. Could you please let me know what you suggest I change from/to?

Sorry for being so daft.

@benvk, the original error states that the SDE feature class is set to areas/polygons and because the text features are point geometries the writer rejects them:

2019-09-04 16:55:30|  45.4|  0.0|ERROR |Cannot write a non-area feature to an area feature class

Can you verify that in the via the ESRI application?

Badge +7

@benvk, the original error states that the SDE feature class is set to areas/polygons and because the text features are point geometries the writer rejects them:

2019-09-04 16:55:30|  45.4|  0.0|ERROR |Cannot write a non-area feature to an area feature class

Can you verify that in the via the ESRI application?

Spot on, somehow when the annotation4_history was 'drop and replace' it created a polygon feature class, not an annotation feature class! Such a simple fix, I was looking for something in FME being incorrect, it was my destination table that was the issue!

Thanks for all your assistance!

Reply