Closed mike123vn closed 6 years ago
I have not used views before. Below is just a guess based on what I read from the docs: https://docs.mongodb.com/manual/core/views/
how can i declare a view with Mongo-model
You could probably use the MongoDB.Db
we get back from connect(...)
, and call createView(...)
on it.
Once you've created a view it sounds like they'll work just like normal collections, only read only.
Mongodb from version 3.4 supported view feature, so how can i declare a view with Mongo-model