'Display the value not present in json but i need it in jsonata

My json { "message":{ "Refno":"654" } } My jsonata: message.{ "data":"account/update", "Refno":($.data='account')?$.Refno:"" } It is not working for me I need output like this if data field is account I need ref no as 654 If my data field is update the ref no is empty string Please help me out if the data field is present in json the code is working but I need the data field in jsonata



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source