Skip to content

Commit 29f28b2

Browse files
Adding objectid filter docs (#173)
* Adding objectid filter docs * Fixing some build issues
1 parent 3e40c30 commit 29f28b2

File tree

1 file changed

+26
-16
lines changed

1 file changed

+26
-16
lines changed

source/filter-documents.txt

Lines changed: 26 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,9 @@ options. You can filter fields with the following data types:
4444

4545
- :ref:`Numeric <filter-numeric>`
4646

47-
- :ref:`String <filter-string>`
47+
- :ref:`String <filter-string-objectid>`
48+
49+
- :ref:`ObjectId <filter-string-objectid>`
4850

4951
- :ref:`Date <filter-date>`
5052

@@ -89,40 +91,48 @@ can filter based on minimum and/or maximum values for that field.
8991
Alternatively, if :guilabel:`Inclusive` is off, |charts| shows
9092
documents where the field is greater than ``5``.
9193

92-
.. _filter-string:
94+
.. _filter-string-objectid:
9395

94-
Filter String Fields
95-
~~~~~~~~~~~~~~~~~~~~
96+
Filter String and ObjectId Fields
97+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
9698

97-
When you drag a string field to the filter panel, |charts| displays a
98-
list of up to 20 distinct field values. If more than 20 distinct values
99-
exist, |charts| displays 20 randomly selected values.
99+
When you drag a string or
100+
:manual:`ObjectId </reference/bson-types/#objectid>` field to the filter
101+
panel, |charts| displays a list of up to 20 distinct field values. If
102+
more than 20 distinct values exist, |charts| displays 20 randomly
103+
selected values.
100104

101105
The list also includes:
102106

103107
- :guilabel:`NULL / MISSING` for documents with ``null`` values for
104108
the field or are missing the field.
105109

106-
- :guilabel:`Empty String` for documents with ``""`` values for the
107-
field.
110+
- :guilabel:`Empty String` for documents with
111+
``""`` values for the string field. (*String fields only.*)
108112

109-
Select the string values to display in the chart. By default, all
113+
Select the values to display in the chart. By default, all
110114
values are selected.
111115

112116
.. tip::
113117

114-
If all strings are selected, you can click :guilabel:`Deselect All`
115-
at the top of the list to hide all strings.
118+
If all values are selected, you can click :guilabel:`Deselect All`
119+
at the top of the list to hide all values.
116120

117-
If not all strings are selected, you can click :guilabel:`Select All`
118-
to return to the default state of having all strings displayed.
121+
If not all values are selected, you can click :guilabel:`Select All`
122+
to return to the default state of having all values displayed.
119123

120-
Display Strings Not in the List
121-
```````````````````````````````
124+
Display Strings and ObjectIds Not in the List
125+
`````````````````````````````````````````````
122126

123127
To display a specific value not included in the list, add the value by
124128
clicking :guilabel:`Add Value`.
125129

130+
.. important::
131+
132+
For :manual:`ObjectId </reference/bson-types/#objectid>` fields,
133+
value you input must be a well-formed ObjectId, or else
134+
|charts| does not accept the value.
135+
126136
To display *all* other values not included in the list, check
127137
:guilabel:`All other values`.
128138

0 commit comments

Comments
 (0)