DbProviderServices.DatabaseExists Method

Definition

Overloads

DatabaseExists(DbConnection, Nullable<Int32>, StoreItemCollection)

Returns a value indicating whether a given database exists on the server.

DatabaseExists(DbConnection, Nullable<Int32>, Lazy<StoreItemCollection>)

Returns a value indicating whether a given database exists on the server.

DatabaseExists(DbConnection, Nullable<Int32>, StoreItemCollection)

Returns a value indicating whether a given database exists on the server.

public bool DatabaseExists (System.Data.Common.DbConnection connection, Nullable<int> commandTimeout, System.Data.Entity.Core.Metadata.Edm.StoreItemCollection storeItemCollection);
member this.DatabaseExists : System.Data.Common.DbConnection * Nullable<int> * System.Data.Entity.Core.Metadata.Edm.StoreItemCollection -> bool

Parameters

connection
DbConnection

Connection to a database whose existence is checked by this method.

commandTimeout
Nullable<Int32>

Execution timeout for any commands needed to determine the existence of the database.

storeItemCollection
StoreItemCollection

The collection of all store items from the model. This parameter is no longer used for determining database existence.

Returns

True if the provider can deduce the database only based on the connection.

Applies to

DatabaseExists(DbConnection, Nullable<Int32>, Lazy<StoreItemCollection>)

Returns a value indicating whether a given database exists on the server.

public bool DatabaseExists (System.Data.Common.DbConnection connection, Nullable<int> commandTimeout, Lazy<System.Data.Entity.Core.Metadata.Edm.StoreItemCollection> storeItemCollection);
member this.DatabaseExists : System.Data.Common.DbConnection * Nullable<int> * Lazy<System.Data.Entity.Core.Metadata.Edm.StoreItemCollection> -> bool
Public Function DatabaseExists (connection As DbConnection, commandTimeout As Nullable(Of Integer), storeItemCollection As Lazy(Of StoreItemCollection)) As Boolean

Parameters

connection
DbConnection

Connection to a database whose existence is checked by this method.

commandTimeout
Nullable<Int32>

Execution timeout for any commands needed to determine the existence of the database.

storeItemCollection
Lazy<StoreItemCollection>

The collection of all store items from the model. This parameter is no longer used for determining database existence.

Returns

True if the provider can deduce the database only based on the connection.

Applies to