DubUrl.Schema 0.112.0

dotnet add package DubUrl.Schema --version 0.112.0
                    
NuGet\Install-Package DubUrl.Schema -Version 0.112.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="DubUrl.Schema" Version="0.112.0" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="DubUrl.Schema" Version="0.112.0" />
                    
Directory.Packages.props
<PackageReference Include="DubUrl.Schema" />
                    
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 DubUrl.Schema --version 0.112.0
                    
#r "nuget: DubUrl.Schema, 0.112.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 DubUrl.Schema@0.112.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=DubUrl.Schema&version=0.112.0
                    
Install as a Cake Addin
#tool nuget:?package=DubUrl.Schema&version=0.112.0
                    
Install as a Cake Tool

DubUrl.Schema

Provider-neutral database schema models, fluent builders, SQL rendering, discovery mapping, and versioned YAML/JSON documents.

The user documentation is published as part of the single DubUrl website.

Table and column tags

Use WithTags on table and column builders or set the Tags property on the schema model. In v1 JSON and YAML, use the optional tags map. For example, tags: { pii: "true" } assigns a string value. Tag keys are case-sensitive, and tags and annotations can use the same key independently.

Providers implement ISchemaTagMetadataReader to discover tags. Inspection reports TableTagCoverage and ColumnTagCoverage separately. A provider that supports neither scope leaves both as Unsupported. Inaccessible or unrepresentable tags make the inspection incomplete.

For deployment, providers implement ITableTagSqlRenderer and IColumnTagSqlRenderer for the scopes they support. SchemaScriptRenderer reports these capabilities separately and rejects declarations for unsupported scopes during planning.

Table hierarchies

Use WithHierarchy(new Hierarchy("id")) on a table builder with a single-column scalar primary key. In schema documents, set hierarchy: { nodeKey: id } on the table. The declaration requires database enforcement of parent existence by default.

var renderer = new SchemaScriptRenderer(dialect);
var hierarchies = renderer.PreflightHierarchies(schema);

Preflight reports each table's representation, enforcement, and any diagnostic. It uses the renderer's dialect and options without connecting to a database. A plan with IsSupported set to false prevents DDL generation.

DuckDB generates a nullable parent_id with the node key's type and a self-referencing foreign key in CREATE TABLE. Each row with a null parent is a root. The foreign key checks that parents exist and permits cycles. Insert a parent before any statement that inserts a child referencing it. Set requireParentExists to false to allow storage without enforcement on a target where enforcement is unavailable.

Inspect Analysis Services metadata

Use the read-only AnalyticalMetadataInspector with the ADOMD provider registered for the connection URL. The inspector lists visible catalogs and reads objects in the connection's current catalog. The URL overload opens and disposes its own connection. The overload taking an already open connection leaves its ownership and selected catalog with the caller.

using DubUrl.Discovery;
using DubUrl.Schema;

var result = await new AnalyticalMetadataInspector().InspectAsync(connectionUrl, cancellationToken);
var measures = result.Objects.Where(item => item.Id.Kind == AnalyticalObjectKind.Measure);
var measuresComplete = result.Coverage[AnalyticalFeature.Measures] == AnalyticalCoverage.Available;

The tabular reader supplies tables, columns, measures, and perspectives. On endpoints without modern tabular rowsets, it can read table and column inventory from legacy DBSCHEMA rowsets and measures from MDSCHEMA. The multidimensional reader supplies cubes, dimensions, hierarchies, levels, measures, and perspectives. Parent IDs link objects in their own scope. Use PerspectiveMembers for membership, Caption for display, and Id or a reported UniqueName for identity. Native rowset IDs are catalog or scope specific and can change if objects are recreated.

Check coverage before treating a missing object as a failed assertion. An available collection can be empty. Partial, unsupported, and inaccessible metadata have separate coverage values. Data types carry the native rowset value, the normalized DbType when known, and any reported length, precision, or scale. Missing facets have null values. A missing or unmapped type is diagnosed per object. Named sets, member properties, standalone measure groups, and dimension and measure-group relationship assertions are outside this inspector's current coverage.

For live consumer checks, set DUBURL_ADOMD_TABULAR_TEST_URL and DUBURL_ADOMD_MULTIDIM_TEST_URL to test models with the requested object types and run the filter FullyQualifiedName~AnalyticalMetadataInspectorTests in DubUrl.Schema.Testing.

Build and test

dotnet build DubUrl.Schema.sln -c Release
dotnet test DubUrl.Schema.Testing -c Release -f net10.0 --no-build
dotnet test DubUrl.Schema.Documents.Testing -c Release -f net10.0 --no-build

CI selects a complete stable DubUrl release for the provider fixtures. Directory.Build.props sets separate minimum versions for DubUrl Core and the provider fixtures. Use -p:DubUrlCoreVersion=<candidate> to validate another Core and ADOMD release, or -p:DubUrlVersion=<candidate> to select a different provider fixture release. See real-database QA and validation.

Discovery identities preserve provider-native qualifiers: SQLite main and attached aliases belong to MetadataName.Database and DatabaseObjectName.Database; they are not schemas. Use DiscoveryOptions.Databases to select aliases, Schemas for actual schemas, and Catalogs for catalogs. These filters also apply to views and their inventory; table filters can match any combination of literal qualifier components. Referenced-table closure preserves each target's complete identity. Rendered attached names require the same aliases to exist in the destination connection.

Git hooks

Enable the repository's pre-push check after cloning:

git config --local core.hooksPath .githooks
dotnet restore DubUrl.Schema.sln

The hook requires the .NET SDK on PATH and Bash (provided by Git for Windows on Windows). It runs dotnet format DubUrl.Schema.sln analyzers --verify-no-changes --no-restore and rejects pushes with analyzer violations. The StyleCop rules in .editorconfig match Expressif's CodeFactor policy.

To apply available analyzer fixes, run dotnet format DubUrl.Schema.sln analyzers --no-restore, review the changes, and rerun the check. Resolve any remaining diagnostics before pushing.

Source was extracted from Seddryck/DubUrl commit 7606da8d030c869dab0dd9d9946dcdd962dfe000; earlier file history remains available there. Public namespaces, package identities, supported TFMs, and document URLs are preserved.

See provider-owned table definitions and physical options.

Product Compatible and additional computed target framework versions.
.NET net8.0 is compatible.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed.  net9.0 is compatible.  net9.0-android was computed.  net9.0-browser was computed.  net9.0-ios was computed.  net9.0-maccatalyst was computed.  net9.0-macos was computed.  net9.0-tvos was computed.  net9.0-windows was computed.  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 (17)

Showing the top 5 NuGet packages that depend on DubUrl.Schema:

Package Downloads
Packata.Provisioners

Packata is a library for consuming Data Package v2 files. The Packata.Provisioners package specializes in providing a relational engine on top of the content of the package.

DubUrl.Schema.Documents

Versioned YAML and JSON schema documents for DubUrl.

DubUrl.Application

Transport-neutral application services for validating, rendering, and deploying DubUrl schema documents, and managing curated connectors.

DubUrl.Provider.SqlServer

SQL Server dialect, mapping, and rewriting for DubUrl.

DubUrl.Provider.MySql

MySQL-family dialects, mapping, and rewriting for DubUrl.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
0.112.0 0 11/28/2026
0.111.0 1,152 11/27/2026
0.110.0 206 11/17/2026
0.109.0 1,332 11/15/2026
0.108.0 435 11/15/2026
0.107.0 1,450 11/13/2026
0.106.0 1,287 11/13/2026
0.105.0 1,268 11/12/2026
0.104.0 5,294 11/10/2026
0.103.0 240 11/10/2026
0.102.1 121 11/9/2026
0.102.0 797 11/9/2026
0.101.4 127 11/6/2026
0.101.3 238 11/3/2026
0.101.2 115 11/3/2026
0.101.1 118 11/3/2026
0.101.0 119 11/3/2026
0.100.1 218 11/1/2026
0.100.0 124 11/1/2026
0.55.1 8,476 10/31/2026
Loading failed