Adds a 'comment' to the cursor. http://mongodb.com/docs/manual/reference/operator/comment/ :param comment: A string to attach to the query to help interpret and trace the operation in the server logs and in profile data. .. versionadded:: 2.7
(self, comment: Any)
| 790 | return self |
| 791 | |
| 792 | def comment(self, comment: Any) -> Cursor[_DocumentType]: |
| 793 | """Adds a 'comment' to the cursor. |
| 794 | |
| 795 | http://mongodb.com/docs/manual/reference/operator/comment/ |
| 796 | |
| 797 | :param comment: A string to attach to the query to help interpret and |
| 798 | trace the operation in the server logs and in profile data. |
| 799 | |
| 800 | .. versionadded:: 2.7 |
| 801 | """ |
| 802 | self._check_okay_to_chain() |
| 803 | self._comment = comment |
| 804 | return self |
| 805 | |
| 806 | def where(self, code: Union[str, Code]) -> Cursor[_DocumentType]: |
| 807 | """Adds a `$where`_ clause to this query. |