{"id":15002460,"url":"https://github.com/sdrapkin/securitydriven.tinyorm","last_synced_at":"2025-05-15T09:00:18.788Z","repository":{"id":49346149,"uuid":"78056162","full_name":"sdrapkin/SecurityDriven.TinyORM","owner":"sdrapkin","description":".NET micro ORM done right.","archived":false,"fork":false,"pushed_at":"2025-02-12T14:39:22.000Z","size":251,"stargazers_count":305,"open_issues_count":2,"forks_count":20,"subscribers_count":23,"default_branch":"master","last_synced_at":"2025-05-09T02:08:03.529Z","etag":null,"topics":["micro-orm","mssql","orm","sql","sql-server"],"latest_commit_sha":null,"homepage":null,"language":"C#","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"ms-pl","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/sdrapkin.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":".github/CODEOWNERS","security":"SecurityDriven.TinyORM.Tests/App.config","support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2017-01-04T21:54:47.000Z","updated_at":"2025-02-12T14:39:27.000Z","dependencies_parsed_at":"2023-01-30T01:45:56.027Z","dependency_job_id":"677f4eea-1a0e-461a-a036-4d9eebdabccd","html_url":"https://github.com/sdrapkin/SecurityDriven.TinyORM","commit_stats":{"total_commits":228,"total_committers":2,"mean_commits":114.0,"dds":0.09210526315789469,"last_synced_commit":"d2bef86ba07899e4c75250c88676bc639c4ac3b1"},"previous_names":[],"tags_count":4,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sdrapkin%2FSecurityDriven.TinyORM","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sdrapkin%2FSecurityDriven.TinyORM/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sdrapkin%2FSecurityDriven.TinyORM/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sdrapkin%2FSecurityDriven.TinyORM/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/sdrapkin","download_url":"https://codeload.github.com/sdrapkin/SecurityDriven.TinyORM/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":254310509,"owners_count":22049467,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["micro-orm","mssql","orm","sql","sql-server"],"created_at":"2024-09-24T18:50:27.028Z","updated_at":"2025-05-15T09:00:18.619Z","avatar_url":"https://github.com/sdrapkin.png","language":"C#","readme":"![TinyORM](TinyORM-Logo.png \"TinyORM\")\n# Simple, fast, and secure micro ORM for .NET [![NuGet](https://img.shields.io/nuget/v/TinyORM.svg)](https://www.nuget.org/packages/TinyORM/)\n\n**TinyORM** by [Stan Drapkin](https://github.com/sdrapkin \"Stan Drapkin\") [sdrapkin at sdprime dot com]\n\n## [Documentation](https://github.com/sdrapkin/SecurityDriven.TinyORM/wiki): [wiki](https://github.com/sdrapkin/SecurityDriven.TinyORM/wiki) ##\n\n## Features: ##\n1.  Focused on **SQL Server** (any `SqlClient`-based db engine). [Azure SQL](https://docs.microsoft.com/en-us/azure/sql-database/sql-database-technical-overview) is supported as well.\n2.  **Intuitive, tiny, simple API**. This is usually the hardest part for libraries to get right.\n3.  **Does not obscure or reinvent `T-SQL`**. If you prefer APIs that hide `T-SQL` incompetence, look [elsewhere](https://en.wikipedia.org/wiki/Entity_Framework).\n4.  **Very fast.** As fast as competition (`Dapper`, `OrmLite`, `LLBLGen`, `EF Core`, etc. [benchmarks](https://gist.github.com/sdrapkin/c2d310e0f42b18d8f2beae789294faa8)). \n5.  **Seamlessly transactional** and **safe**. Transactions are not merely supported - they are the default.\n\t* [`XACT_ABORT=ON`](https://docs.microsoft.com/en-us/sql/t-sql/statements/set-xact-abort-transact-sql) (automatic transaction rollback on runtime T-SQL errors).\n\t* Custom transaction scopes are declared via standard `TransactionScope` instance (created via `TinyORM`.`DbContext`.`CreateTransactionScope()` factory).\n6.  **Transparent connection management**. One less thing to worry about and screw up. Never think about connections again.\n7.  `Task`-based `async` API (ie. *the* API). All calls are buffered (focus on safety and fast connection release).\n8.  **POCOs** or `anonymous` objects are fine. No inheritance, interface, or attribute requirements.\n9.  Returns `dynamic` entities which can be consumed directly, or projected to statically-typed objects (*fast!*).\n\t* Either strict (perfect-match) or relaxed (best-effort) projection of `dynamic` to statically-typed objects.\n10. Full **parameterization**, with parameter list expansion (ex. `WHERE Id IN (@IdList)`). This also helps prevent SQL injection.\n\t* `CHAR`, `VARCHAR`, `NCHAR`, `NVARCHAR` support for `string` parameters. \n11. Single or multiple Result Sets.\n12. **Snapshots** provide change-tracking, with `UPDATE` `T-SQL` generation for partial updates.\n13. Intelligent **batched \\*bulk\\* command sequences** via `QueryBatch` (not just for `INSERT` - for all `CREATE/UPDATE/DELETE/MERGE` commands).\n14. **Streaming data-out** support (ex. streaming out `BLOBs`/files).\n15. **Auditing**\n\t* Caller identity tracking (*which user made the call?*).\n\t* Callsite tracking (*which source code filename, method, and line# made the call?*).\n16. Helpers for `CREATE`, `UPDATE`, `DELETE`, and `UPSERT` `T-SQL` generation.\n17. `SequentialGuid` generator for **fragmentation-free**, **unique**, **unguessable**, **code-generated** clustered `uniqueidentifier` indexes.\n18. c# 10.0 in `safe` mode. Compiled `any cpu` for .NET 4.5.2+ and NetStandard 2.0/.NET Core 2.0+.\n19. Tiny codebase. Tiny ~45k `.dll`.\n20. `TinyORM` on [NuGet](https://www.nuget.org/packages/tinyorm) (`Install-Package TinyORM`).\n21. **MS-PL** ([Microsoft Public](LICENSE.md)) license. If MS-PL does not suit you, contact me.\n\nIf you are serious about SQL Server, give **TinyORM** a try (even if you're a `Dapper` fan).\n\n## Simple TinyORM query ##\n```csharp\nvar db = DbContext.Create(connString);\nvar query = await db.QueryAsync(\"select [Answer] = @a + @b\", new { @a = 123, @b = 2 });\n\nConsole.WriteLine(query.First().Answer); // prints \"125\"\n\nstatic string connString = \"Data Source=.\\\\SQL2012; Initial Catalog=tempdb; Integrated Security=True;\";\n```\n\n## ##\nNature graphic by [Freepik](http://www.flaticon.com/authors/freepik) is licensed under [CC BY 3.0](http://creativecommons.org/licenses/by/3.0/).\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsdrapkin%2Fsecuritydriven.tinyorm","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsdrapkin%2Fsecuritydriven.tinyorm","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsdrapkin%2Fsecuritydriven.tinyorm/lists"}