语言

AzureSynapseDbContextOptionsBuilder.UseCompatibilityLevel(Int32) 方法

定义

设置 EF Core 在与数据库交互时将使用的Azure Synapse兼容级别。 这允许将 EF Core 配置为使用较旧的(或更新)版本的Azure Synapse。 默认值为 30.

public virtual Microsoft.EntityFrameworkCore.Infrastructure.AzureSynapseDbContextOptionsBuilder UseCompatibilityLevel(int compatibilityLevel);
abstract member UseCompatibilityLevel : int -> Microsoft.EntityFrameworkCore.Infrastructure.AzureSynapseDbContextOptionsBuilder
override this.UseCompatibilityLevel : int -> Microsoft.EntityFrameworkCore.Infrastructure.AzureSynapseDbContextOptionsBuilder
Public Overridable Function UseCompatibilityLevel (compatibilityLevel As Integer) As AzureSynapseDbContextOptionsBuilder

参数

compatibilityLevel
Int32

要用于数据库的兼容级别。

返回

注解

有关详细信息和示例,请参阅有关兼容级别的使用 DbContextOptions 和Azure Synapse文档。

适用于