Skip to main content
Question

fme_basename of WKT files not loading correctly

  • October 14, 2019
  • 2 replies
  • 26 views

Hi,

I am using the WKT reader for text files containing each one WKT polygon.

I want to write them to shapefiles, using their basename as fanout.

But all files are getting the same value for fme_basename.

 

 

This post is closed to further activity.
It may be an old question, an answered question, an implemented idea, or a notification-only post.
Please check post dates before relying on any information in a question or answer.
For follow-up or related questions, please post a new question or idea.
If there is a genuine update to be made, please contact us and request that the post is reopened.

2 replies

ebygomm
Influencer
Forum|alt.badge.img+46
  • Influencer
  • October 14, 2019

I see the same behaviour, can you use a text reader followed by a geometryreplacer as a workaround?


chrisatsafe
Contributor
Forum|alt.badge.img+2
  • Contributor
  • October 17, 2019

Hi @jwisb,

Another option here is to use a Directory and File Pathnames Reader and point to the folder containing the WKT files. Then use a FeatureReader to read in the files using the path_windows attribute that is created by the Directory and Pathnames reader to set the dataset parameter in the FeatureReader:

You can then expose the fme_basename in the Attribute and Geometry Handling Section of the FeatureReader in the <Generic> Port > Attributes to Expose.

Not quite as fast as using the WKT reader but gives you options if you want to fanout based on the basename.

Hope that helps.