SharpCoreDB.Functional 1.8.0

dotnet add package SharpCoreDB.Functional --version 1.8.0
                    
NuGet\Install-Package SharpCoreDB.Functional -Version 1.8.0
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="SharpCoreDB.Functional" Version="1.8.0" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="SharpCoreDB.Functional" Version="1.8.0" />
                    
Directory.Packages.props
<PackageReference Include="SharpCoreDB.Functional" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add SharpCoreDB.Functional --version 1.8.0
                    
#r "nuget: SharpCoreDB.Functional, 1.8.0"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package SharpCoreDB.Functional@1.8.0
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=SharpCoreDB.Functional&version=1.8.0
                    
Install as a Cake Addin
#tool nuget:?package=SharpCoreDB.Functional&version=1.8.0
                    
Install as a Cake Tool

SharpCoreDB.Functional

Functional facade for SharpCoreDB.

Version: v1.8.0
Package: SharpCoreDB.Functional

Patch updates in v1.8.0

  • ✅ Aligned package metadata and version references to the synchronized 1.8.0 release line.
  • ✅ Release automation now publishes all packable SharpCoreDB packages in CI/CD.

Features

  • Functional wrappers for database workflows
  • Core types: Option<T>, Fin<T>, Seq<T>, and Unit
  • Functional query/command style extensions over Database and IDatabase
  • Works as base module for Dapper and EF Core functional adapters

Changes in v1.8.0

  • Functional package introduced and aligned to v1.8.0
  • Documentation aligned with modular adapter ecosystem
  • Maintains optional architecture with transitive dependency flow

Installation

dotnet add package SharpCoreDB.Functional --version 1.8.0
  • SharpCoreDB.Functional.Dapper
  • SharpCoreDB.Functional.EntityFrameworkCore

Documentation

  • docs/INDEX.md

MVP API

  • Database.Functional() / IDatabase.Functional() entry points
  • GetByIdAsync<T>(...) -> Task<Option<T>>
  • FindOneAsync<T>(...) -> Task<Option<T>>
  • QueryAsync<T>(...) -> Task<Seq<T>>
  • InsertAsync<T>(...) -> Task<Fin<Unit>>
  • UpdateAsync<T>(...) -> Task<Fin<Unit>>
  • DeleteAsync(...) -> Task<Fin<Unit>>
  • CountAsync(...) -> Task<long>

Functional SQL Syntax (v1.8.0)

The functional facade supports SQL extensions that map directly to Option<T> behavior.

Example

SELECT Id, Name, Email OPTIONALLY FROM Users
WHERE Email IS SOME;

Execute from C#

var fdb = database.Functional();

var users = await fdb.ExecuteFunctionalSqlAsync<UserDto>(
    "SELECT Id, Name, Email OPTIONALLY FROM Users WHERE Email IS SOME");

Supported keywords

  • OPTIONALLY FROM
  • IS SOME
  • IS NONE
  • MATCH SOME <column>
  • MATCH NONE <column>
  • UNWRAP <column> AS <alias> [DEFAULT '<value>']

Verification tests

dotnet test tests/SharpCoreDB.Functional.Tests --filter "FullyQualifiedName~FunctionalSqlSyntaxTests"

Source: tests/SharpCoreDB.Functional.Tests/FunctionalSqlSyntaxTests.cs

Chaining example

var dbf = database.Functional();

var result = await dbf
    .GetByIdAsync<User>(Tables.Users, userId, cancellationToken: ct)
    .Map(opt => opt.Map(user => user with { LastSeenUtc = DateTime.UtcNow }))
    .Map(opt => opt.ToFin(Errors.UserNotFound));

result.Match(
    Succ: _ => Console.WriteLine("updated"),
    Fail: err => Console.WriteLine(err.Message));

Product Compatible and additional computed target framework versions.
.NET net10.0 is compatible.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages (3)

Showing the top 3 NuGet packages that depend on SharpCoreDB.Functional:

Package Downloads
SharpCoreDB.Data.Provider

Data provider layer for SharpCoreDB on .NET 10.

SharpCoreDB.Functional.EntityFrameworkCore

Entity Framework Core adapter for SharpCoreDB.Functional with zero-dependency Option/Fin APIs and fluent functional composition for .NET 10 and C# 14.

SharpCoreDB.Functional.Dapper

Dapper adapter for SharpCoreDB.Functional with zero-dependency Option/Fin APIs and fluent functional composition for .NET 10 and C# 14.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
1.8.0 154 4/29/2026
1.7.2 164 4/28/2026
1.7.1 149 4/26/2026
1.6.0 209 3/23/2026

v1.8.0: Functional facade with zero-dependency Option/Fin/Seq/Unit types and fluent composition.