Skip to content

GetSchema("DataTypes") does not return entries for JSON and VECTOR types #3833

@igor-tkachev

Description

@igor-tkachev

Describe the bug

SqlConnection.GetSchema("DataTypes") does not include rows for the built-in SQL Server types JSON and VECTOR.

To reproduce

using Microsoft.Data.SqlClient;

using var connection = new SqlConnection("Server=.;Database=master;Integrated Security=true;");
connection.Open();

var table = connection.GetSchema("DataTypes");

bool hasJson   = table.Rows.Cast<DataRow>().Any(r => ((string)r["TypeName"]).Equals("json",   StringComparison.OrdinalIgnoreCase));
bool hasVector = table.Rows.Cast<DataRow>().Any(r => ((string)r["TypeName"]).Equals("vector", StringComparison.OrdinalIgnoreCase));

Console.WriteLine($"JSON found:   {hasJson}");
Console.WriteLine($"VECTOR found: {hasVector}");

Actual: both return false
Expected: both types should be included

Further technical details

Microsoft.Data.SqlClient version: all versions, including prerelease
.NET target: all
SQL Server version: SQL Server 2025
Operating system: any

Metadata

Metadata

Labels

No labels
No labels

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions