Skip to main content
Solved

LandXML to LandXML

  • October 23, 2017
  • 7 replies
  • 53 views

Forum|alt.badge.img

Hi,

I Would like to read a directory with 76 LandXML with one alignment each.

Replacing the current name of each Alignment name with the basename file.

and Place all the result in one LandXML or separately

- I used the StringReplacer and replace the feature Name for the basename.

Its working fine on the Inspector

but cannot exporting the landxml file.

I try to export all LandXML in one file and export all LandXML in basename alignement file..

But having problem with LandXML exporter.

Do you know how i can merge it ?

 

Thx!

Best answer by syllan

Hi !

Its not empty

The StringReplacer work, it replace the orginal name for the filename in the Inspector.

The problem its when i try to export it in LandXML.

If I just remove the StringReplacer Transformer. And joint the Reader to the Writer. Its not working too.

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.

7 replies

danilo_fme
Celebrity
Forum|alt.badge.img+52
  • Celebrity
  • October 23, 2017

Hi @syllan,

In Inspector the attribute fme_basename is empty or not?

Thanks,

Danilo


Forum|alt.badge.img
  • Author
  • Best Answer
  • October 23, 2017

Hi !

Its not empty

The StringReplacer work, it replace the orginal name for the filename in the Inspector.

The problem its when i try to export it in LandXML.

If I just remove the StringReplacer Transformer. And joint the Reader to the Writer. Its not working too.


danilo_fme
Celebrity
Forum|alt.badge.img+52
  • Celebrity
  • October 23, 2017

Hi !

Its not empty

The StringReplacer work, it replace the orginal name for the filename in the Inspector.

The problem its when i try to export it in LandXML.

If I just remove the StringReplacer Transformer. And joint the Reader to the Writer. Its not working too.

Perfect.

 

Try to enable the Fanout option in Navigator.

 

 

I simulated here with this option and its works!

 

 

 

Thanks,

 

Danilo

 


Forum|alt.badge.img
  • Author
  • October 23, 2017

Hi !

Its not empty

The StringReplacer work, it replace the orginal name for the filename in the Inspector.

The problem its when i try to export it in LandXML.

If I just remove the StringReplacer Transformer. And joint the Reader to the Writer. Its not working too.

There was a problem writing out the `Alignments' and `Alignment' elements. The problem was: `Item id must be globally unique.'.

 

LandXML requires that 'Name' attributes are globally unique. If features have non-unique values for the 'Name' attribute, the attribute will need to be renamed.

 

There was a problem writing out the `Alignments' and `Alignment' elements. The problem was: `Item is already in a collection.'.

 

A fatal error has occurred. Check the logfile above for details

 

... Last line repeated 3 times ...

 

 

 


trentatsafe
Safer
Forum|alt.badge.img+6
  • Safer
  • October 23, 2017

Hello @syllan,

 

I believe the issue you are experiencing is due to reading in multiple LandXML files and trying to write to a single output file. It appears that there are features that are required to be globally unique(values cannot be present more than once) in your current document. Secondly, it appears that there are attributes that likely share names as well.

 

Alternatively, you may be able to create a new LandXML by using a XMLTemplater. You can use your existing LandXML document as a template to populate. More information and an example can be found here:

 

 

https://docs.safe.com/fme/2017.1/html/FME_Desktop_Documentation/FME_Transformers/Transformers/xmltemplater.htm

https://knowledge.safe.com/articles/30940/xml-writing-with-xmltemplater.html


Forum|alt.badge.img
  • Author
  • October 23, 2017

Hi !

Its not empty

The StringReplacer work, it replace the orginal name for the filename in the Inspector.

The problem its when i try to export it in LandXML.

If I just remove the StringReplacer Transformer. And joint the Reader to the Writer. Its not working too.

OK I Find the problem : 2 Files contains 2 ALINGMENT.. That why its not working.

 

The Fanout solution work THX

danilo_fme
Celebrity
Forum|alt.badge.img+52
  • Celebrity
  • October 23, 2017
OK I Find the problem : 2 Files contains 2 ALINGMENT.. That why its not working.

 

The Fanout solution work THX
Oh Great, that the problem was solved @syllan :)