Can I use Entity Framework Code First Approach with NoSql Database? And how NoSql can be advantage over SQL Database for a application with large data.
When you use NoSQL databases for your infrastructure data tier, you typically do not use an ORM like Entity Framework Core. Instead you use the API provided by the NoSQL engine, such as Azure Cosmos DB, MongoDB, Cassandra, RavenDB, CouchDB, or Azure Storage Tables.
The result set written by SQL on relational model is similar to NoSQL data model which is aggregate data model. Therefore, entity relationship diagram and relational model can be used in NoSQL database design.
3 Answers. Show activity on this post. Support for NoSQL database providers such as Azure Table Storage, Redis and others (like MongoDb) are still in EF Core team backlog and has not been implemented yet and will not be implemented for Core 1.0.
Short answer - no, it's for sure possible, but not reasonable. MongoDB is document database and not support any physical relations between collections. EF is a good fit for relational databases like SQL, MySQL, etc. MongoDB works faster with embedded documents.
I have been using BrightstarDb (http://www.brightstardb.com/) for the past few months and it offers code-first model generation based on Entity Framework.
BrightstarDb is a NoSql database that is also an RDF triplestore, so it's allows for more complicated relations between Entities than most traditional NoSql databases.
Can i use Entity Framework Code First Approach with NoSql Database ?
No, you can't.
and how NoSql can be advantage over SQL Database for a application with large data.
Quote:
NoSQL database systems are often highly optimized for retrieve and append operations and often offer little functionality beyond record storage (e.g. key-value stores). The reduced run time flexibility compared to full SQL systems is compensated by significant gains in scalability and performance for certain data models.
In short, NoSQL database management systems are useful when working with a huge quantity of data and the data's nature does not require a relational model for the data structure. The data could be structured, but it is of minimal importance and what really matters is the ability to store and retrieve great quantities of data, and not the relationships between the elements. For example, to store millions of key-value pairs in one or a few associative arrays or to store millions of data records. This is particularly useful for statistical or real-time analyses for growing list of elements (such as Twitter posts or the Internet server logs from a big group of users).
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With