The Sharp Factory
Esc
↑ ↓ to moveEnter to open

Quick start

From a database to working C# code in five steps. Each step links to the page that explains it in full.

  1. 1

    Download and run the app

    Download takes you to the latest release on GitHub. Pick the file for your system: TheSharpFactory-win-x64.zip for Windows (win-arm64 on ARM), TheSharpFactory-osx-arm64.zip for a Mac with Apple silicon (osx-x64 on Intel) or TheSharpFactory-linux-x64.tar.gz for Linux. Unzip it and run it. It is self-contained: no .NET install and no account. The macOS app is not signed yet, so the first time, right-click it and choose Open.

    Download
  2. 2

    Create a model from your database

    Choose New, connect to SQL Server, pick the tables, views, procedures, functions and sequences you want, and save the model file.

    Model generation →
  3. 3

    Preview, then Sync into your solution

    Open Sync, pick your .sln or .slnx (or create one), check the preview of every file, then Sync. The same works from the command line:

    $ sharpfactory sync model.edmj MyApp.slnx --preview
  4. 4

    Set up your project

    Add the package, the connection string and the repository container to the project that uses the generated code.

    Project setup →
  5. 5

    Write your first query

    Use the repositories to create, read, update and delete, and the Query class to filter, sort and page.

    Query syntax →

Prefer video?

Short walkthroughs of the first model, CRUD, queries, procedures and more. They show an earlier version of the app.