Xrm.DataManager.Framework.Tds 2026.0.2

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

Xrm.DataManager.Framework.Tds

Retrieve Microsoft Dataverse records with SQL (TDS endpoint) in Xrm.DataManager.Framework batch jobs.

NuGet License

SQL simplifies and speeds up data retrieval (joins, aggregates, filters on linked tables) : records are then processed by the framework (multi threading, retries, progress file, logging).

Getting started

Prerequisites

  • Enable TDS endpoint setting enabled on the Dataverse environment
  • Dataverse connection with Entra ID authentication (OAuth, ClientSecret or Certificate) : its access token is used for SQL connection
  • Network access to TDS endpoint port (1433 or 5558)

Write a job

using Xrm.DataManager.Framework;

public class AnonymizeContactsJob : SqlFullProcessDataJobBase
{
    public AnonymizeContactsJob(JobSettings jobSettings, JobProcessParameters parameters) : base(jobSettings, parameters) { }

    public override string GetName() => "Anonymize contacts";

    // contactid is added automatically when missing
    public override string GetSqlQuery() => "SELECT TOP 1000 emailaddress1, createdby, createdbyname FROM contact WHERE emailaddress1 LIKE '%.com'";

    public override void ProcessRecord(JobExecutionContext context)
    {
        var email = context.Record.GetSqlValue<string>("emailaddress1");
        var creator = context.Record.GetSqlEntityReference("createdby", "systemuser");

        // SQL columns are not in Attributes : only modified columns are sent
        context.Record["emailaddress1"] = email.Replace(".com", ".fake");
        context.Proxy.Update(context.Record);
    }
}

Run it like any other job :

using (var processor = new JobProcessor())
{
    processor.Execute<AnonymizeContactsJob>();
}

How records are built

  • The query is parsed before execution : it must be a single SELECT statement.
  • Primary key column of the records table (first table of FROM clause, or GetSqlEntityName()) is added if missing and used as record id.
  • Other columns are stored in Record.FormattedValues (culture invariant strings) and read with GetSqlValue<T>(column) / GetSqlEntityReference(column, table) : Attributes stay empty, so the record can be updated without sending SQL columns back.
  • Lookups and choices are returned as {column} (id or value) and {column}name (label), dates are UTC.

Direct SQL access

TdsClient retrieves records or opens a SQL connection outside of SqlFullProcessDataJobBase (ex : in PreOperation, or on another connection) :

// Optional parameters : command timeout (seconds) and port
var tdsClient = new TdsClient(proxy, Logger);
var accounts = tdsClient.RetrieveRecords("SELECT name, accountnumber FROM account WHERE statecode = 0");

Settings

Used by SqlFullProcessDataJobBase :

Key (appSettings) Default Description
Tds.Port 1433 TDS endpoint port (1433 or 5558, depending on your firewall)
Tds.CommandTimeout.Seconds 300 SQL query timeout

Limits

  • Read only : 5 minutes query timeout (2 minutes for SELECT * and joins).
  • SQL queries don't trigger RetrieveMultiple plugins.
  • Elastic tables aren't supported, NOLOCK hint should be avoided.

Documentation

Feedback

Questions, bugs and suggestions : GitHub issues.

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. 
.NET Framework net48 is compatible.  net481 was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
2026.0.2 49 10/26/2026
2026.0.1 57 10/26/2026