File tree Expand file tree Collapse file tree 2 files changed +4
-4
lines changed
includes/usage-examples/code-snippets Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -34,7 +34,7 @@ func main() {
3434 }()
3535
3636 // begin watch
37- coll := client .Database ("insertDB " ).Collection ("haikus " )
37+ coll := client .Database ("sample_restaurants " ).Collection ("restaurants " )
3838 pipeline := mongo.Pipeline {bson.D {{"$match" , bson.D {{"operationType" , "insert" }}}}}
3939 cs , err := coll .Watch (context .TODO (), pipeline )
4040 if err != nil {
Original file line number Diff line number Diff line change @@ -14,7 +14,7 @@ Example
1414
1515.. include:: /includes/usage-examples/run-example-tip.rst
1616
17- The following example opens a change stream on the ``haikus `` collection
17+ The following example opens a change stream on the ``restaurants `` collection
1818and prints inserted documents:
1919
2020.. literalinclude:: /includes/usage-examples/code-snippets/watch.go
@@ -40,8 +40,8 @@ output:
4040 // results truncated
4141 {
4242 "_id": ...,
43- "title ": "Record of a Shriveled Datum ",
44- "text ": "No bytes, no problem. Inserting a document. In MongoDB "
43+ "name ": "8282 ",
44+ "cuisine ": "Korean "
4545 }
4646
4747.. important::
You can’t perform that action at this time.
0 commit comments