About JSONata

mBoard latest version was supporting search JSON with JSONata.

JSONata is an open-source, lightweight query and transformation language specifically designed for JSON (JavaScript Object Notation) data. It allows users to extract, filter, manipulate, and restructure JSON data with a concise and intuitive syntax.

Key features and capabilities of JSONata include:

  • Querying: It provides a powerful and easy-to-learn syntax for navigating and selecting data within JSON documents, including nested objects and arrays.
  • Transformation: JSONata enables the transformation of JSON data structures, allowing the creation of new JSON objects or arrays based on specific requirements.
  • Expressions: It supports a rich set of expressions for various operations, including string manipulation, arithmetic calculations, and logical comparisons.
  • Functions: JSONata offers a comprehensive library of built-in functions for common tasks like mapping, filtering, sorting, summing, and string operations. It also allows for the definition of custom functions.
  • Compact Notation: JSONata expressions are designed to be compact and expressive, facilitating efficient data manipulation.

Source: https://jsonata.org/

About JSON

Let’s start with three text files that represent typical JSON-like mappings.

  • A JSON object contains zero, one, or more key-value pairs, also called properties. The object is surrounded by curly braces {}. Every key-value pair is separated by a comma. The order of the key-value pair is irrelevant.
  • A key-value pair consists of a key and a value, separated by a colon (:). The key is a string, which identifies the key-value pair. The value can be any of the following data types:
  • In melons_raw.json , we have a JSON entry per line. The value should be a String or Number.
  • In melons_array.json , we have a JSON array. The value should be Array List.
  • In melons_map.json , we have a JSON that fits well in a Java Map. The value should be a Map.