IDbConnectionFactory.CreateConnection(String) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Creates a connection based on the given database name or connection string.
public System.Data.Common.DbConnection CreateConnection (string nameOrConnectionString);
abstract member CreateConnection : string -> System.Data.Common.DbConnection
Public Function CreateConnection (nameOrConnectionString As String) As DbConnection
Parameters
- nameOrConnectionString
- String
The database name or connection string.
Returns
An initialized DbConnection.
Applies to
Collaborate with us on GitHub
The source for this content can be found on GitHub, where you can also create and review issues and pull requests. For more information, see our contributor guide.
Entity Framework