Partilhar via


SqlServerDbContextOptionsExtensions Class

Definition

SQL Server specific extension methods for DbContextOptionsBuilder.

public static class SqlServerDbContextOptionsExtensions
type SqlServerDbContextOptionsExtensions = class
Public Module SqlServerDbContextOptionsExtensions
Inheritance
SqlServerDbContextOptionsExtensions

Remarks

See Using DbContextOptions, and Accessing SQL Server, Azure SQL, Azure Synapse databases with EF Core for more information and examples.

Methods

ConfigureSqlEngine(DbContextOptionsBuilder, Action<SqlEngineDbContextOptionsBuilder>)

Configures the context to connect to any of SQL Server, Azure SQL, Azure Synapse databases, but without initially setting any DbConnection or connection string.

ConfigureSqlEngine<TContext>(DbContextOptionsBuilder<TContext>, Action<SqlEngineDbContextOptionsBuilder>)

Configures the context to connect to any of SQL Server, Azure SQL, Azure Synapse databases, but without initially setting any DbConnection or connection string.

UseAzureSql(DbContextOptionsBuilder, Action<AzureSqlDbContextOptionsBuilder>)

Configures the context to connect to a Azure SQL database, but without initially setting any DbConnection or connection string.

UseAzureSql(DbContextOptionsBuilder, DbConnection, Action<AzureSqlDbContextOptionsBuilder>)

Configures the context to connect to a Azure SQL database.

UseAzureSql(DbContextOptionsBuilder, DbConnection, Boolean, Action<AzureSqlDbContextOptionsBuilder>)

Configures the context to connect to a Azure SQL database.

UseAzureSql(DbContextOptionsBuilder, String, Action<AzureSqlDbContextOptionsBuilder>)

Configures the context to connect to a Azure SQL database.

UseAzureSql<TContext>(DbContextOptionsBuilder<TContext>, Action<AzureSqlDbContextOptionsBuilder>)

Configures the context to connect to a Azure SQL database, but without initially setting any DbConnection or connection string.

UseAzureSql<TContext>(DbContextOptionsBuilder<TContext>, DbConnection, Action<AzureSqlDbContextOptionsBuilder>)

Configures the context to connect to a Azure SQL database.

UseAzureSql<TContext>(DbContextOptionsBuilder<TContext>, DbConnection, Boolean, Action<AzureSqlDbContextOptionsBuilder>)

Configures the context to connect to a Azure SQL database.

UseAzureSql<TContext>(DbContextOptionsBuilder<TContext>, String, Action<AzureSqlDbContextOptionsBuilder>)

Configures the context to connect to a Azure SQL database.

UseAzureSynapse(DbContextOptionsBuilder, Action<AzureSynapseDbContextOptionsBuilder>)

Configures the context to connect to a Azure Synapse database, but without initially setting any DbConnection or connection string.

UseAzureSynapse(DbContextOptionsBuilder, DbConnection, Action<AzureSynapseDbContextOptionsBuilder>)

Configures the context to connect to a Azure Synapse database.

UseAzureSynapse(DbContextOptionsBuilder, DbConnection, Boolean, Action<AzureSynapseDbContextOptionsBuilder>)

Configures the context to connect to a Azure Synapse database.

UseAzureSynapse(DbContextOptionsBuilder, String, Action<AzureSynapseDbContextOptionsBuilder>)

Configures the context to connect to a Azure Synapse database.

UseAzureSynapse<TContext>(DbContextOptionsBuilder<TContext>, Action<AzureSynapseDbContextOptionsBuilder>)

Configures the context to connect to a Azure Synapse database, but without initially setting any DbConnection or connection string.

UseAzureSynapse<TContext>(DbContextOptionsBuilder<TContext>, DbConnection, Action<AzureSynapseDbContextOptionsBuilder>)

Configures the context to connect to a Azure Synapse database.

UseAzureSynapse<TContext>(DbContextOptionsBuilder<TContext>, DbConnection, Boolean, Action<AzureSynapseDbContextOptionsBuilder>)

Configures the context to connect to a Azure Synapse database.

UseAzureSynapse<TContext>(DbContextOptionsBuilder<TContext>, String, Action<AzureSynapseDbContextOptionsBuilder>)

Configures the context to connect to a Azure Synapse database.

UseSqlServer(DbContextOptionsBuilder, Action<SqlServerDbContextOptionsBuilder>)

Configures the context to connect to a SQL Server database, but without initially setting any DbConnection or connection string.

UseSqlServer(DbContextOptionsBuilder, DbConnection, Action<SqlServerDbContextOptionsBuilder>)

Configures the context to connect to a SQL Server database.

UseSqlServer(DbContextOptionsBuilder, DbConnection, Boolean, Action<SqlServerDbContextOptionsBuilder>)

Configures the context to connect to a SQL Server database.

UseSqlServer(DbContextOptionsBuilder, String, Action<SqlServerDbContextOptionsBuilder>)

Configures the context to connect to a SQL Server database.

UseSqlServer<TContext>(DbContextOptionsBuilder<TContext>, Action<SqlServerDbContextOptionsBuilder>)

Configures the context to connect to a SQL Server database, but without initially setting any DbConnection or connection string.

UseSqlServer<TContext>(DbContextOptionsBuilder<TContext>, DbConnection, Action<SqlServerDbContextOptionsBuilder>)

Configures the context to connect to a SQL Server database.

UseSqlServer<TContext>(DbContextOptionsBuilder<TContext>, DbConnection, Boolean, Action<SqlServerDbContextOptionsBuilder>)

Configures the context to connect to a SQL Server database.

UseSqlServer<TContext>(DbContextOptionsBuilder<TContext>, String, Action<SqlServerDbContextOptionsBuilder>)

Configures the context to connect to a SQL Server database.

Applies to