tidwall / tile38

Real-time Geospatial and Geofencing
https://tile38.com
MIT License
9.09k stars 569 forks source link

WHERE clause with nested properties not working #720

Closed iansalazar444 closed 7 months ago

iansalazar444 commented 7 months ago

Describe the bug While following this part of the document (I'll attach the image after this paragraph), I tried querying an object that was a JSON field, but it doesn't work. Querying by just a single field works, though. image

To Reproduce

  1. Run SET fleet truck4 FIELD info '{"speed":60,"age":21,"name":"Tom"}' POINT 33 -112
  2. Run INTERSECTS fleet WHERE 'info.speed > 45 && info.age < 21' BOUNDS 30 -120 40 -100

Expected behavior The object truck4 should return.

Actual behavior The result is empty (see attached image as reference) image

Operating System (please complete the following information):

iansalazar444 commented 7 months ago

I was able to fix this by using double quotes instead of single quotes