Get Started with Databases and Data Access using C Sharp

This repository contains sample projects for getting started with C# for working with data and managing databases.

There are several ways to access databases by writing C# code and using the .NET ecosystem. A list of the most popular options can be found below. Choose the approach that is the best fit for the application that you want to write!

  • Entity Framework Core
    • Write C# to generate complex SQL queries by using language-integrated queries (LINQ)
      • Get started without having to learn SQL
      • Scale your SQL queries by writing code
    • Database connection with just a connection string
    • Maps data to objects, which means you can take a code-first approach to working with data
    • Powerful and scalable
  • Dapper
    • Write your own SQL queries
    • Database connection with just a connection string
    • Maps data to objects
    • Lightweight with high performance
      • Useful for scenarios with large number of queries and operations
  • ADO.NET
    • Write your own SQL queries
    • Write your own database connection
    • Work with data as plaintext that can be processed into objects
    • Supports all scenarios

C# can be used to work with a large number of databases, including but not limited to:

  • sSQL Server
  • Azure SQL
  • SQLite
  • PostgreSQL
  • MySQL
  • Oracle
  • IBM