JSON Row Combiner and Writer

All of the values in the selected JSON column are combined into a single JSON structure and written to a file. Depending on the Place resulting JSON setting, the combined rows are either placed Under root key (as the value of that key) or At top level in the file. You can use Additional properties to add custom key/value pairs next to the combined JSON. The Combine rows as option controls whether the rows are collected into an Array or into an Object with key (using a key column to name each entry). (The JSON content in the file can be pretty-printed.) For example, when combining rows as an array under a root key with additional properties, the output looks like this:

{
  "JSON key": [
    { "json": "from Row1" },
    { "json": "from Row2" }
  ],
  "custom key": "custom value"
}

Options

JSON column
The JSON column providing the values for the resulting JSON.
Output file location
Location to save the file (can also be a URL).
If output file already exists
How to handle output file already existing.
  • Fail: Prevent node from executing.
  • Overwrite file: Replace the file if it exists.
Format
Format for the resulting JSON.
  • Dense: No whitespace.
  • Pretty print: Use multiple lines and indentation.
Combine rows as
Configure how to collect the JSON values.
  • Array: The rows are collected into a JSON array.
  • Object with key: The rows become an object within another object with the keys specified by the selected column's values (will fail if there are duplicates).
Object key column
Column which provides keys when collecting rows into JSON object.
Place resulting JSON
How to structure the resulting JSON output.
  • Under root key: Place the resulting JSON under a root key alongside optional additional properties.
  • At top level: Generate resulting JSON as top level object.
Root object key
Key under which to place the resulting JSON.
Additional properties
Additional key/value pairs to add to the root object.
  • Key: Additional property key.
  • Value: Additional property value.

Input Ports

Icon
Table with a JSON column

Output Ports

This node has no output ports

Views

This node has no views

Workflows

Links

Developers

You want to see the source code for this node? Click the following button and we’ll use our super-powers to find it for you.