« Listal vs Librarything: No contest | Main | Cristiano Ronaldo's wonderful skills »

ADO.NET makes developing for different databases harder

Hmm... I suddenly realized that my focus these days is development. Interesting.

I'm wondering if there is an easier way for a .NET application to natively support different databases in the same code base. For instance, when I do SQL Server, the .NET Data Provider I would use is SqlConnection. If it is OLEDB, then it's the OleDbConnection namespace.

Now each of these namespaces have their own DataReader object, which is the primary data object I use. How can I write the application such that I can automatically choose which one to use (based on a parameter), without coding different sections for each data provider?

MSDN, here I come!

TrackBack

TrackBack URL for this entry:
http://www.donnyyap.com/villeapp/mt-tb.cgi/46

Post a comment

(If you haven't left a comment here before, you may need to be approved by the site owner before your comment will appear. Until then, it won't appear on the entry. Thanks for waiting.)