Skip to main content
Solved

Geometry Replacer - missing attribute after output

  • February 13, 2023
  • 4 replies
  • 61 views

rzrnc
Participant
Forum|alt.badge.img+2
  • Participant

Hi;

I have FME Desktop 2023.0 BETA (FME(R) 2023.0.0.0 (20230130 - Build 23226 - WIN64))

The FME workbench consists of Sql reader, Geometry Replacer, and Dwg Writer.

Sql reader reads a simple view from the database. Among others, the field 'autocad_entity' with the value 'autocad_insert' and the field 'autocad_block_name' with the value 'kc'. (I use those fields or fme attributes to create blocks through dwg writer). Reader reads everything correctly. After the reader comes the Geometry Replacer, which works correctly. However, after the Geometry Replacer, the 'autocad_entity' attribute has the value 'missing'. All other attributes are ok. Attributes are read from the database as varchar datatype.

Thanks;

sqlReaderOutputgeometryReplacerOutput

Best answer by markatsafe

rzrnc wrote:

Thanks for quick answer and posted link. I'm confused with removing 'autocad_insert' attribute, because this is not geometry type(just varchar). 'geom' is SQL server geometry type attribute which is correct replaced and removed. So if I understand correctly, here is problem in my 'ambiguous' naming of attribute?!

@rzrnc​ the autocad_entity describes the type of geometry that the autocad writer can expect. It is linked to the fme_geometry/fme_type attribute which also describes the type of geometry. So if the geometry changes (as in the GeometryRpelacer), then fme_geometry/fme_type will be reset and you now have a conflict - so FME drops the autocd_entity since it now reflects the wrong geometry structure. If you need to preserve teh original entity name, rename the attribute before GeometryReplacer

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

4 replies

egge
Contributor
Forum|alt.badge.img+14
  • Contributor
  • February 13, 2023

I don't think the fact that you are using 2023.0 BETA is very relevant here. It should work the same in the current version of FME...

See the Usage Notes of the GeometryReplacer:

"If a feature with existing geometry has that geometry replaced using this transformer, and the new geometry is a different type (replacing an area with a point, for example), the feature's existing geometry-related format-specific attributes (such as geodb_type, autocad_entity, or shapefile_type) will be removed."

 

HTH,

 

Egge-Jan


rzrnc
Participant
Forum|alt.badge.img+2
  • Author
  • Participant
  • February 13, 2023
egge wrote:

I don't think the fact that you are using 2023.0 BETA is very relevant here. It should work the same in the current version of FME...

See the Usage Notes of the GeometryReplacer:

"If a feature with existing geometry has that geometry replaced using this transformer, and the new geometry is a different type (replacing an area with a point, for example), the feature's existing geometry-related format-specific attributes (such as geodb_type, autocad_entity, or shapefile_type) will be removed."

 

HTH,

 

Egge-Jan

Thanks for quick answer and posted link. I'm confused with removing 'autocad_insert' attribute, because this is not geometry type(just varchar). 'geom' is SQL server geometry type attribute which is correct replaced and removed. So if I understand correctly, here is problem in my 'ambiguous' naming of attribute?!


Forum|alt.badge.img+2
  • Best Answer
  • February 14, 2023
rzrnc wrote:

Thanks for quick answer and posted link. I'm confused with removing 'autocad_insert' attribute, because this is not geometry type(just varchar). 'geom' is SQL server geometry type attribute which is correct replaced and removed. So if I understand correctly, here is problem in my 'ambiguous' naming of attribute?!

@rzrnc​ the autocad_entity describes the type of geometry that the autocad writer can expect. It is linked to the fme_geometry/fme_type attribute which also describes the type of geometry. So if the geometry changes (as in the GeometryRpelacer), then fme_geometry/fme_type will be reset and you now have a conflict - so FME drops the autocd_entity since it now reflects the wrong geometry structure. If you need to preserve teh original entity name, rename the attribute before GeometryReplacer


rzrnc
Participant
Forum|alt.badge.img+2
  • Author
  • Participant
  • February 15, 2023
rzrnc wrote:

Thanks for quick answer and posted link. I'm confused with removing 'autocad_insert' attribute, because this is not geometry type(just varchar). 'geom' is SQL server geometry type attribute which is correct replaced and removed. So if I understand correctly, here is problem in my 'ambiguous' naming of attribute?!

Thank you very much for the detailed explanation. I understand now.


Reply


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