Skip to main content
Question

Empty Lists in JSON Templater

  • May 7, 2020
  • 1 reply
  • 6 views

mmccart
Contributor
Forum|alt.badge.img+16

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

1 reply

mmccart
Contributor
Forum|alt.badge.img+16
  • Author
  • Contributor
  • 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.


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