C# Database Access Patterns
Streamlines RDBMS integration in C# for PostgreSQL, MySQL, DuckDB, and legacy systems using optimized access patterns and drivers.
This skill provides specialized guidance for C# developers working with a diverse range of database systems, from modern PostgreSQL and DuckDB instances to legacy SQL Server and DBISAM environments. It offers standardized patterns for library selection (Npgsql, MySql.Data, ODBC), type-safe mapping via the ExecuteAndMap pattern, and robust connection management. By following these production-proven implementation details, developers can ensure proper parameterization, efficient timeout handling, and optimized performance for complex operations like querying Parquet files or handling PostgreSQL arrays.
Características Principales
015 GitHub stars
02DuckDB ODBC patterns for direct Parquet file querying
03Native driver optimization for PostgreSQL (Npgsql) and MySQL
04Type-safe result mapping using the ExecuteAndMap lambda pattern
05Standardized parameter handling to prevent SQL injection across different drivers
06Legacy system support for Sage1000, X3, and Exportmaster (DBISAM)
Casos de Uso
01Migrating legacy ODBC database connections to high-performance native drivers
02Implementing type-safe data access layers in C# ServiceLib projects
03Performing ad-hoc PostgreSQL queries using specialized CLI tool configurations