Back to Knowledge Base
Knowledge Base Database DSN, DSN-less and OLEDB Connections, Which One?

DSN, DSN-less and OLEDB Connections, Which One?

Database 07/11/2026
<p><span style="font-family: arial, helvetica, sans-serif; font-size: small;">Solution</span></p>
<p><span style="border-collapse: collapse; line-height: 16px;"><span style="font-family: arial, helvetica, sans-serif; font-size: small;"> </span></span></p>
<div class="MsoNormal" style="margin-top: 0cm; margin-right: 0cm; margin-bottom: 0pt; margin-left: 0cm;">When connecting a database, DSN-less connections are superior to System DSN connections in performance. However, there will be no noticeable improvement in performance for smaller sites which have few concurrent connections only.</div>
<div class="MsoNormal" style="margin-top: 0cm; margin-right: 0cm; margin-bottom: 0pt; margin-left: 0cm;"><br />Although a DSN-less connection is operationally identical to a DSN but it doesn't have to access registry during connecting process. For DSN-less connection, all required information will be specified in the connection string instead of storing in registry.<br /><br /></div>
<div class="MsoNormal" style="margin-top: 0cm; margin-right: 0cm; margin-bottom: 0pt; margin-left: 0cm;">In practice, youre recommended to use OLEDB connections over these two type of connections. Why? Its because OLEDB can provide better performance in database connections and faster access to data.<br /><br /></div>
<div class="MsoNormal" style="margin-top: 0cm; margin-right: 0cm; margin-bottom: 0pt; margin-left: 0cm;">The Connection String for OLEDB would be:</div>
<p> </p>
<div class="MsoNormal" style="margin-top: 0cm; margin-right: 0cm; margin-bottom: 0pt; margin-left: 0cm;"><span style="color: #99cc00;"><span style="color: #008000;">"Provider=ProviderName; Data Source=DatabaseSource; Initial Catalog=DatabaseName; User ID=UserID; Password=Password"</span></span></div>
<p> </p>
Was this article helpful?