Introducing NPoco

NPoco is the new library from my PetaPoco branch. If you don’t know what PetaPoco is, it is a MicroORM that enables quick and fast database access using raw sql. Why did I create this library? Well there was becoming too much divergence and it was always a pain that I couldn’t obtain my branch through NuGet.

Currently I’m working on V2 which is available now on NuGet if you use the –Pre console switch or by selecting “Include Prerelease” in Visual Studio. This does not include the T4 templates. I do take pull requests if you like this feature of PetaPoco and want it in NPoco.

There is also a fair bit of documentation about NPoco located at the Wiki. It includes basic documentation of how to use the library as well as the features only in NPoco. Some of these include.

  1. Query onto an existing object
  2. One-to-Many query helpers
  3. Mapping to Nested Objects query helpers
  4. Dictionary<string, object> and object[] queries for dynamic results
  5. Change tracking for updates
  6. Composite Primary Key support
  7. Queries that returns Multiple Result Sets
  8. Fluent Mappings including Conventional based mappings
  9. Version column support
  10. IDatabase interface
  11. Sql Templating

I’m still finalising all the documentation for these features, so if documentation doesn’t exist for one of the let me know and I will prioritise that feature.

The code is also available at Github, so go have a look, give it a try, send me a pull request and let me know how you get on.


** I did try to get my changes for PetaPoco merged back in to the main project, however I feel this will be better for my changes going forward.

This entry was posted in .NET and tagged . Bookmark the permalink.

3 Responses to Introducing NPoco

  1. Matt says:

    Thanks for making this available! The change tracking support is definately an awesome feature!

  2. Matt says:

    Also, which version of petapoco is this based off of? It seems to indicate 4.0 instead of 5.0.1 version of petapoco??

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s