microrm 0.8.1
Micro ORM for SQLite3
To use this package, run the following command in your project's root directory:
						Manual usage
						
						Put the following dependency into your project's dependences section:
					
Micro ORM for SQLite3
Very simple ORM with single backend (SQLite3).
struct Foo { ulong id; string text; ulong ts; }
struct Baz { string one; double two; }
struct Bar { ulong id; float value; Baz baz; }
enum schema = buildSchema!(Foo, Bar);
auto db = new MDatabase("test.db");
db.run(schema);
writeln("Bar count: ", db.count!Bar.run);
db.del!Foo.where("ts <", cts - cast(ulong)1e8).run;
db.insert(Foo(0, "hello", cts), Foo(20, "world", cts));
db.insert(Foo(0, "hello", cts), Foo(0, "world", cts));
db.insertOrReplace(Foo(1, "hello", cts), Foo(3, "world", cts));
See example/source/app.d
- 0.8.1 released 4 years ago
- deviator/microrm
- MIT
- Copyright © 2017, Oleg Butko
- Authors:
- Dependencies:
- d2sqlite3
- Versions:
- 
						
 Show all 10 versions0.8.1 2021-May-06 0.8.0 2019-May-31 0.7.0 2017-Oct-18 0.6.0 2017-Oct-04 0.5.0 2017-Sep-17 
- Download Stats:
- 
						- 
								1 downloads today 
- 
								5 downloads this week 
- 
								24 downloads this month 
- 
								247 downloads total 
 
- 
								
- Score:
- 2.1
- Short URL:
- microrm.dub.pm