For those new to OrmDb...
|
|
OrmDB is a simple, fast and lightweight embedded .NET ORM tool which was inspired by the equivalent other tools.
OrmDB works across .NET ADO providers such as MsSql, MySql, Oracle, PostgreSql and SQLite.
You dont need the re-write the queries for different databases with OrmDb. You can execute ONE statement on different databases and its native connectors.
OrmDB prepares your statements for your connection.
|
How doest it look?
If the query as shown below will be executed...
Odb.SQL.Select(x => x.From(th).Skip(5).Top(10));
actually the SQL as shown below, are executed.
MsSql :
SELECT h.[id]
FROM [header]ASh
ORDER BY (SELECT NULL) OFFSET 5 ROWS FETCH NEXT 10 ROWS ONLY
PostgreSql :
SELECT h."id"
FROM "header"ASh
OFFSET 5 ROWS FETCH NEXT 10 ROWS ONLY
Oracle :
SELECT h."id"
FROM "header" h
OFFSET 5 ROWS FETCH NEXT 10 ROWS ONLY
MySql :
SELECT h.`id`
FROM `header` h
LIMIT 5, 10
Sqlite :
SELECT h."id"
FROM "header"ASh
LIMIT 5, 10
Where to use?
- All desktop/web applications need to communicate with a database
- Multi database operation
- Multi client application
- .Net / Asp.Net / .Net Core / Asp.Net Core
License
MIT