Jq filter compilation (jqcompile)
How does it work in the search window?
Select Create column in the search window toolbar, then select the Jq filter compilation operation. You need to specify one argument:
The data type of the values in the new column is jq.
We want to extract the city value from a simple JSON object contained in the json column. To do it, first we need to create a jq filter that outputs the specific part of the json (the city value), and then use the Jq evaluation (jqeval) operation to extract it.
The easiest way to do it is hovering over the json column and clicking P on your keyboard to open the JSON object in pretty-print, as seen in the Jq evaluation (jqeval) example. This method adds a JSON value as a jq filter to be used in the operation by simply clicking the required value in the JSON.
However, you can also create a new column manually using the Jq filter compilation operation to get the jq filter. In the capture below, we add the string .city to be converted to a jq filter that will start the city value of our JSON.
jq filters always start with a dot, so the string included in this operation must always include it.
Now that we have generated the required jq filter, we use the Jq evaluation (jqeval) operation to extract the city values in our JSON:
How does it work in LINQ?
Use the operator
as... and add the operation syntax to create the new column. This is the syntax for the Jq evaluation operation:
The LINQ query corresponding to the above example is: