Difference between Sql Connection and OLEDB Connection
Asked Answered
F

2

12

What is the difference between the SQL Connection and OLEDB Connection? Is that OLEDB is common to all (also SQL Server)? To which are all Servers, OLEDB is using?

Farnsworth answered 20/8, 2011 at 7:6 Comment(1)
possible duplicate of SQLCommand/SQLConnection vs OleDbCommand/OleDbConnectionMaceio
W
16

The advantage of using OleDbConnection is flexibility. You can change your database (for instance, move to Oracle)and not have to change your code.

If you using SQLServer as backend then use SQLConnection for better performance.

check with this link http://social.msdn.microsoft.com/Forums/en-US/vbgeneral/thread/fadb2742-d75a-49fb-a839-b2d4a9183998/

OleDbConnection : You can connect to any database, which you have provide for that.

Tip: use Universal Data Link File

enter image description here

Woodworth answered 20/8, 2011 at 7:11 Comment(0)
A
9

SqlConnection is designed to access SQL Server, while OleDbConnection is designed to access any database.

Attalie answered 20/8, 2011 at 7:10 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.