Question

Excel to KML - Styling Folder Hierarchy

  • 19 July 2019
  • 2 replies
  • 27 views

Let me start off by saying I'm very new to FME. I'm trying to transform data from Excel to KML and I want the output in KML to create a folder hierarchy using some of the attributes from the data.

Each record in my spreadsheet has some of the following information. Here is a small sample:

DECADE: 1940s

YEAR: 1946

FLIGHT: 1

IMAGE: 1-1-1.tif

 

What I want to do is use this data to create the folder hierarchy in the KML file.

Example of end folders in the KML:

Top level=1940s (DECADE)

with sub of 1946 (YEAR)

with sub of 1 (FLIGHT)

then my feature of 1-1-1.tif (IMAGE)

How would I best accomplish this??

 


2 replies

Badge +2

I believe what you want to do is modify the kml_parent, kml_document, kml_id, and kml_name attributes. Each folder has to be created with a kml_parent unless it's the root folder.

kml_document = name of your KML file

kml_parent = folder containing feature

kml_id, kml_name = feature as displayed in tree

This article should really help: https://knowledge.safe.com/articles/74315/creating-kml-folders-through-kml-ids.html

 

I have a screenshot sample attached. I was trying to sort of figure out the same thing. I created some random data and merged it with a point using a creator and featuremerger. You can ignore those, because your spreadsheet should work fine. All the kml_parent attributes should be unique. If a sub-flight is "1" then all the flight data that has the same sub-flight number will go in one folder in the first decade and year (I guess). I hope this helps you out.

That did the trick! This information definitely got me on the right track! Thank you for the posted answer!

Reply