Find All Data Providers Installed On A Machine
This post shows you how to find Data Providers installed on a machine. Data providers in .NET Framework provide the plumbing necessary to connect to databases. There are different data providers available which can connect to SQL Server, Oracle or other databases through OleDb. You can find the data providers installed on your machine by looking at Machine.config file. In particular you will be looking for DbProviderFactories element under System.Data. In the screenshot below you can see data providers installed on my machine.
A list of data providers can also be retrieved by code. This sample shows you how to retrieve a list of data providers in code.
DataTable dataProviders = DbProviderFactories.GetFactoryClasses(); foreach (DataRow provider in dataProviders.Rows) { Console.WriteLine(provider[0].ToString()); }
In the code above I am displaying the name of provider. Here is my output.

2 Responses to Find All Data Providers Installed On A Machine
Leave a Reply Cancel reply
Top Posts
- LINQ To SQL Tutorial
- LINQ To SQL Join On Multiple Conditions
- Code Sample: Programmatically Download File Using C#
- Windows 7 Control Panel In Classic Mode
- More Details Emerge On Microsoft Master Certification
- Use SqlConnection With LINQ To SQL
- Free Icons And Images With Visual Studio 2008
- Capture XML In WCF Service
- Dynamic Sort With LINQ
- StyleCop Tutorial
Tags
.Net 2010 ADO.NET ASP.NET Azure Blogging Books Browsers C# Certification Cloud Computing Code Snippets Community Data Services Eclipse Entity Framework Google IDE Java LINQ Mac Microsoft Museum NetBeans Office Oracle REST SharePoint Silverlight SQL Server T-SQL Tips Tools Training Visual Studio Visual Studio 2010 WCF Web Windows Windows 7 Windows Forms Windows Live WMI WPF XAML


You can do the same thing in PowerShell by running this one-liner
[System.Data.Common.DbProviderFactories]::GetFactoryClasses() | % { $_.Name }
Thanks Ravikanth,
Truly powerful :)