Skip to main content
Solved

jsontemplater - help needed for beginner

  • August 19, 2014
  • 1 reply
  • 31 views

Forum|alt.badge.img
Hi,

 

 

I am following the example of the village that can be found here: http://docs.safe.com/fme/html/FME_Transformers/Default.htm#Transformers/jsontemplater.htm

 

 

my root is the following:

 

 

{

 

    "title": "Atlas de l'immigration - Exemple d'atlas dynamique",

 

    "layers": [

 

        fme:process-features("LAYERS"),

 

    ]

 

}

 

 

my sub names LAYERS is the following:

 

{

 

    "name": fme:get-attribute("fme_basename"),

 

}

 

 

However I got this error:

 

|JSONTemplater(XMLTemplaterFactory):The following error occurred near line 5, column 5 of the query:

 

|JSONTemplater(XMLTemplaterFactory): invalid expression: syntax error, unexpected "]"

 

 

I thought I was following the doc example carefuly. Why this error?

 

Best answer by david_r

Hi,

 

 

you must remove your comma at the end of line 4, as well as on line 2 of the LAYERS sub.

 

 

David
View original
Did this help you find an answer to your question?
This post is closed to further activity.
It may be a question with a best answer, an implemented idea, or just a post needing no comment.
If you have a follow-up or related question, 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.

1 reply

david_r
Evangelist
  • Best Answer
  • August 19, 2014
Hi,

 

 

you must remove your comma at the end of line 4, as well as on line 2 of the LAYERS sub.

 

 

David

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