ORM(Object Relational Mapping)
I aim to explain what an ORM does, as well as the pros and cons of using them in your projects.
Last updated
I aim to explain what an ORM does, as well as the pros and cons of using them in your projects.
Last updated
Select * from users where email = 'test@test.com';
///This is a Sql code.
var orm = require('generic-orm-library');
var user=orm("users").where({email:'test@test.com'});
//In these rows,we ve used an imaginary ORM library to
execute the exact same query,except we can write it in C#.
we have books class and
we want to get which writer name is "Orhan Pamuk" ;
List books= new List();
sql = "SELECT * FROM LibraryWHERE Writer= 'Orhan Pamuk'";
data = query(sql); // I over simplify ...
while (row = data.next())
{
books k = new Kitap();
k.Writer=row["Writer"];
books.add(kitap);
}List Books= db.Books.Where(x=>x.Writer=="Orhan Pamuk").ToList();