36
Views
1
Comments
[JSONata Transformation] "S0207: Unexpected end of expression" error displaying when using JSONata Transform
jsonata-transformation
Reactive icon
Forge asset by Stefan Weber
Application Type
Reactive
Service Studio Version
11.53.43 (Build 62091)
Platform Version
11.18.1 (Build 37828)

Hi,

I've just installed the JSONata Transform forge component along with the Demo install.

When Json_Transform is called, I'm getting a "S0207: Unexpected end of expression" error.

This happens on the Demo as well as where I've used it on our Reactive application.

I've tried using a JSON example from the JSONata documentation site as well and the same error displays.



I've tried transforming JSON on Demo with the following 2 examples:

#Example 1 JSON

{

  "Account": {

    "Account Name": "Firefly",

    "Order": [

      {

        "OrderID": "order103",

        "Product": [

          {

            "Product Name": "Bowler Hat",

            "ProductID": 858383,

            "SKU": "0406654608",

            "Description": {

              "Colour": "Purple",

              "Width": 300,

              "Height": 200,

              "Depth": 210,

              "Weight": 0.75

            },

            "Price": 34.45,

            "Quantity": 2

          },

          {

            "Product Name": "Trilby hat",

            "ProductID": 858236,

            "SKU": "0406634348",

            "Description": {

              "Colour": "Orange",

              "Width": 300,

              "Height": 200,

              "Depth": 210,

              "Weight": 0.6

            },

            "Price": 21.67,

            "Quantity": 1

          }

        ]

      },

      {

        "OrderID": "order104",

        "Product": [

          {

            "Product Name": "Bowler Hat",

            "ProductID": 858383,

            "SKU": "040657863",

            "Description": {

              "Colour": "Purple",

              "Width": 300,

              "Height": 200,

              "Depth": 210,

              "Weight": 0.75

            },

            "Price": 34.45,

            "Quantity": 4

          },

          {

            "ProductID": 345664,

            "SKU": "0406654603",

            "Product Name": "Cloak",

            "Description": {

              "Colour": "Black",

              "Width": 30,

              "Height": 20,

              "Depth": 210,

              "Weight": 2

            },

            "Price": 107.99,

            "Quantity": 1

          }

        ]

      }

    ]

  }

}


#Example 2 JSON:

{

 "Status":"Healthy",

 "TotalDuration":"00:00:00.0169198",

 "Timestamp":"2023-10-13T06:28:12.0627812+00:00",

 "Entries":

 {

  "Application-SQL-DbContext":

  {

   "Status":"Healthy",

   "Description":null,

   "Duration":"00:00:00.0037357",

   "Data":{},

   "Exception":null,

   "Tags":["SQL","DBContext","Application"]

   },

   "Application-ServiceBus-Raise":

   {

    "Status":"Healthy",

    "Description":null,

    "Duration":"00:00:00.0046046",

    "Data":{},

    "Exception":null,

    "Tags":["ServiceBus","Application"]

    },

    "Application-BlobStorage":

    {

     "Status":"Healthy",

     "Description":null,

     "Duration":"00:00:00.0048347",

     "Data":{},

     "Exception":null,

     "Tags":["BlobStorage","Application"]

     }

 }

}

2021-10-09 07-57-44
Stefan Weber
 
MVP

Hi Vong,

your didnt provide a JSONata transformation in the screen above. Only providing the source document does not work.

Stefan

Community GuidelinesBe kind and respectful, give credit to the original source of content, and search for duplicates before posting.