Skip to main content
Question

Empty Lists in JSON Templater

  • May 7, 2020
  • 1 reply
  • 12 views

mmccart
Enthusiast
Forum|alt.badge.img+27

I am trying to figure out how to insert empty lists into a JSON Templator as an empty bracket like this:

"materials" : [],

Currently, I can't only get it to look like this:

"materials" : [

{

"materialBridgeId" : null,

"materialTypeName" : null,

"materialName" : null,

"quantity" : null,

"tamsUnitOfMeasureId" : null,

"tamsUnitOfMeasureName" : null,

"tamsStockpileId" : null,

"tamsStockpileName" : null,

"isDerivedFromCirus" : null

}

],

Any thoughts on I can achieve the empty elements listed above?

Thanks!

Mark

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.

1 reply

mmccart
Enthusiast
Forum|alt.badge.img+27
  • Author
  • Enthusiast
  • 81 replies
  • May 12, 2020

I finally figured it out with a little help from this article: https://knowledge.safe.com/articles/44294/json-writing-with-jsontemplater.html

I ended up having to explode and expose the list items, but got the desired output.