# Query JSON / JSONATA not returning information

**URL:** https://community.glideapps.com/t/query-json-jsonata-not-returning-information/65853
**Category:** Ask for Help
**Created:** [September 6, 2023, 9:25pm UTC](https://community.glideapps.com/t/query-json-jsonata-not-returning-information/65853 "2023-09-06T21:25:56Z")
**Posts on this page:** 8
**Page:** 1

<div class="post-metadata">

### Author: ![Tim\_Gestels](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/tim_gestels/32/44044_2.png) [@Tim\_Gestels](https://community.glideapps.com/u/Tim_Gestels)
#### Post date: [September 6, 2023, 9:25pm UTC](https://community.glideapps.com/t/query-json-jsonata-not-returning-information/65853/1 "2023-09-06T21:25:56Z")

</div>

I have a very simple JSON object in a text column:

{“out-0”:“Who is the king of Belgium? The current king of Belgium is King Philippe. He was born on April 15, 1960, and is the eldest son of King Albert II and Queen Paola. As King, he serves as the General of the Belgian army and has also been involved in promoting Belgian companies and establishing business relations with other countries.”}

When I do Query JSON Column on this with out-0 as the JSONata query it doesn’t return anything.

 ![Schermafbeelding 2023-09-06 om 23.21.03](https://us1.discourse-cdn.com/flex002/uploads/glideapps/original/3X/4/b/4b1211c638cf58d1830187755daee7b1b4b4d121.png)

When I try the following Javascript it also doesn’t do anything:  
// Parse the JSON string into a JSON object  
const jsonObject = JSON.parse(p1);

// Extract the value associated with the key “out-0”  
const result = jsonObject[‘out-0’];

// Now, ‘result’ contains the value you’re interested in

When I do an Excel formula it works, however I assume this will only work for very simple JSON objects.

Excel Formula: MID(A1, LEN(“{”“out-0"”:“”“) + 1, LEN(A1) - LEN(”{““out-0"”:”“”) - LEN(“”“}”))

Any idea on why the JSONata is not working on my JSON object?  
btw I tried different types of columns including the single row and also different jsonata queries such as: [‘out-0’]

Many thanks!

Tim

---

<div class="post-metadata">

### Author: ![gvalero](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/gvalero/32/1037_2.png) [@gvalero](https://community.glideapps.com/u/gvalero)
#### Post date: [September 6, 2023, 11:21pm UTC](https://community.glideapps.com/t/query-json-jsonata-not-returning-information/65853/2 "2023-09-06T23:21:21Z")

</div>

Hola Tim!

I think your dash/hyphen “-” is confusing the expression. JSONata thinks it’s a subtraction expression 😉

Try with:

```auto
  **."out-0"

```

Saludos!

---

<div class="post-metadata">

### Author: ![ThinhDinh](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/thinhdinh/32/49_2.png) [@ThinhDinh](https://community.glideapps.com/u/ThinhDinh)
#### Post date: [September 6, 2023, 11:48pm UTC](https://community.glideapps.com/t/query-json-jsonata-not-returning-information/65853/3 "2023-09-06T23:48:20Z")

</div>

```auto
`out-0`

```

should be enough.

 ![image](https://us1.discourse-cdn.com/flex002/uploads/glideapps/original/3X/e/f/effdd7b6d9cf3dca2aafce23f4c97e2d99b34a1c.jpeg)

JSONata treats white space and dashes as special characters, so when you have them as keys on a root level field, you can bind them to ` characters to escape it.

---

<div class="post-metadata">

### Author: ![gvalero](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/gvalero/32/1037_2.png) [@gvalero](https://community.glideapps.com/u/gvalero)
#### Post date: [September 7, 2023, 1:26am UTC](https://community.glideapps.com/t/query-json-jsonata-not-returning-information/65853/4 "2023-09-07T01:26:33Z")

</div>

> [@ThinhDinh](#):
>
> `out-0`

ufffs… my hat doesn’t have that rabbit! 😀

btw… how are these symbols ( `` ) called in English? … the Spanish language doesn’t have them.

Thanks!

---

<div class="post-metadata">

### Author: ![ThinhDinh](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/thinhdinh/32/49_2.png) [@ThinhDinh](https://community.glideapps.com/u/ThinhDinh)
#### Post date: [September 7, 2023, 1:37am UTC](https://community.glideapps.com/t/query-json-jsonata-not-returning-information/65853/5 "2023-09-07T01:37:13Z")

</div>

> [@gvalero](#):
>
> `

A backtick or backquote, I believe.

---

<div class="post-metadata">

### Author: ![Tim\_Gestels](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/tim_gestels/32/44044_2.png) [@Tim\_Gestels](https://community.glideapps.com/u/Tim_Gestels)
#### Post date: [September 7, 2023, 9:48am UTC](https://community.glideapps.com/t/query-json-jsonata-not-returning-information/65853/6 "2023-09-07T09:48:40Z")

</div>

thanks @gvalero and @ThinhDinh

I was trying ‘out-0’ as well but that didn’t work.  
However with the `out-0` “backtick quotes” and with the solution of gustavo it works.  
However i have no idea where to find these backtick quotes on my Belgium Azerty keyboard 😅

---

<div class="post-metadata">

### Author: ![ThinhDinh](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/thinhdinh/32/49_2.png) [@ThinhDinh](https://community.glideapps.com/u/ThinhDinh)
#### Post date: [September 7, 2023, 9:52am UTC](https://community.glideapps.com/t/query-json-jsonata-not-returning-information/65853/7 "2023-09-07T09:52:24Z")

</div>

It’s left to the number 1 key on my MacOS keyboard. I use a standard one.

---

<div class="post-metadata">

### Author: ![gvalero](https://sea2.discourse-cdn.com/flex002/user_avatar/community.glideapps.com/gvalero/32/1037_2.png) [@gvalero](https://community.glideapps.com/u/gvalero)
#### Post date: [September 7, 2023, 3:03pm UTC](https://community.glideapps.com/t/query-json-jsonata-not-returning-information/65853/8 "2023-09-07T15:03:59Z")

</div>

> [@Tim\_Gestels](#):
>
> my Belgium Azerty keyboard

no way… an AZERTY keyboard??

 ![image](https://us1.discourse-cdn.com/flex002/uploads/glideapps/original/3X/5/9/59934124a6e53ecd4659229dc370e5490dca689d.png)

this will drive us crazy quickly 🥴

This is how our QWERTY keyboard looks like, the differences are noticeable.:

 ![image](https://us1.discourse-cdn.com/flex002/uploads/glideapps/original/3X/7/f/7f7989945b03b21bb599dd5989e69035478cfc63.png)

Saludos!
