Click to See Complete Forum and Search --> : ADOxxx or SQLxxx objects?


devpro
May 13th, 2001, 08:53 AM
I currently have a web site running on NT4 and linked to an Access database. If I want to upgrade to SQLServer I just need to update the connection string in one file.
Now I want to rewrite my site with ASP.NET, but I have a big question. I know that I can use ADOConnection, ADOCommand, ADODataSetCommand etc. to use any OLEDB Provider to be able to change the connection string and pass from Access to SQLServer when I want.
But if I want to take the maximum advantage of SQL Server I should use SQLConnection, SQLxxx ect, right? This is quite difficult, because I still want to be able the Access database, so, do I need to write different code for ADOxxx and SQLxxx objects for Access and SQLServer?

A second question: put that I choose to use the ADOxxx objects for both Access and SQLServer, even if I'm not sure this is the best situation. How can I know if the connection string points to an Access or SQLserver database, in order to use a stored procedure instead of a simple query?

I hope I've been clear enough in explaining myself...
Thank you so much for the help you would like to offer.


- devpro