Skip to content

Commit

Permalink
Correct phrasing of "Query Operators"
Browse files Browse the repository at this point in the history
  • Loading branch information
Shane Kilkelly committed Sep 16, 2016
1 parent 860fe7f commit 77c7254
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 8 deletions.
2 changes: 1 addition & 1 deletion CHANGELOG.md
Expand Up @@ -12,7 +12,7 @@ Released 2016-09-13

Released 2016-09-12

- Advanced Query Operators
- Query Operators (such as `$eq`, `$regex`, ...)
- Add `skip` and `sort` options for `find_one`
- New `remove_many_by_ids` operation
- Add `$created` and `$updated` sorts
Expand Down
4 changes: 2 additions & 2 deletions doc/guide/overview.md
Expand Up @@ -235,7 +235,7 @@ print db['users'].distinct('address.city')
```


## Advanced Queries
## Query Operators

All of the examples so far have queried for documents which match a query document. In other words, the query document should be a sub-set of the matched document. BedquiltDB also supports more advanced query operations. For example, we can test that a certain field does _not equal_ to a given value:

Expand Down Expand Up @@ -274,7 +274,7 @@ print db['orders'].find({
})
```

See the [BedquiltDB Spec](../spec.md#aside-advanced-query-operations) for full documentation on advanced query operations.
See the [BedquiltDB Spec](../spec.md#aside-query-operators) for full documentation on query operators.


## Skip, Limit and Sort
Expand Down
2 changes: 1 addition & 1 deletion doc/guide/updating.md
Expand Up @@ -10,7 +10,7 @@ The BedquiltDB projects strives to preserve backwards-compatibility between rele
- All public functions have been changed to accept `jsonb` parameters rather than `json`
- The `find_one` function now accepts `skip` and `sort` parameters
- Sort specifiers now include `$created` and `$updated` options
- Query operations now support [Advanced Query Operators](../spec.md#aside-advanced-query-operations)
- Query operations now support [Query Operators](../spec.md#aside-query-operators)

Update process:

Expand Down
8 changes: 4 additions & 4 deletions doc/spec.md
Expand Up @@ -359,12 +359,12 @@ users.distinct('lastName') # => ['Smith', 'Clarke', ...]
```


### Aside: Advanced Query Operations
### Aside: Query Operators

Query documents are normally used as a sub-document match, following the semantics of PostgreSQL `@>` operator. A query document may optionally include _Advanced Query Operators_, which take the form of key=>value mappings where the key begins with a `$` character.
Query documents are normally used as a sub-document match, following the semantics of PostgreSQL `@>` operator. A query document may optionally include _Query Operators_, which take the form of key=>value mappings where the key begins with a `$` character.

These query operators can be mixed into a query document at any location, and at any level of nesting,
and will be filtered out of the query before execution. In this way a match query can be comibined with advanced query operators.
and will be filtered out of the query before execution. In this way a match query can be comibined with query operators.

The following operators are supported:

Expand Down Expand Up @@ -526,7 +526,7 @@ collection.find({
})
```

As an example of mixing match queries with advanced query operations, the following query should match all documents which live in either Edinburgh or Glasgow, and have logged in at least twice:
As an example of mixing match queries with query operators, the following query should match all documents which live in either Edinburgh or Glasgow, and have logged in at least twice:
```
users.find({
"address": {
Expand Down

0 comments on commit 77c7254

Please sign in to comment.