Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions content/develop/interact/search-and-query/query/geo-spatial.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,9 +41,9 @@ Allowed units are `m`, `km`, `mi`, and `ft`.

The following query finds all bicycle stores within a radius of 20 miles around London:

```
{{< clients-example query_geo geo1 >}}
FT.SEARCH idx:bicycle "@store_location:[-0.1778 51.5524 20 mi]"
```
{{< /clients-example >}}

## Shape

Expand All @@ -62,12 +62,12 @@ Here is a more detailed explanation of this query:

The following example query verifies if a bicycle is within a pickup zone:

```
{{< clients-example query_geo geo2 >}}
FT.SEARCH idx:bicycle "@pickup_zone:[CONTAINS $bike]" PARAMS 2 bike "POINT(-0.1278 51.5074)" DIALECT 3
```
{{< /clients-example >}}

If you want to find all pickup zones that are approximately within Europe, then you can use the following query:

```
{{< clients-example query_geo geo3 >}}
FT.SEARCH idx:bicycle "@pickup_zone:[WITHIN $europe]" PARAMS 2 europe "POLYGON((-25 35, 40 35, 40 70, -25 70, -25 35))" DIALECT 3
```
{{< /clients-example >}}