DSN vs DSN-less connection?

Discussion in 'Databases' started by Bruce, Apr 2, 2003.

Thread Status:
Threads that have been inactive for 5 years or longer are closed to further replies. Please start a new thread.
  1. Bruce

    Bruce DiscountASP.NET Staff

    From a functional standpoint DSN & DSNLess connection is identical. DSN connection uses a System ODBC Data Source to locate your database file. Whereas, DSNLess connection, you specify the location of the database by physical path.

    The ODBC tool create a system ODBC data source, you can use any name you wish. Once you have the DSN setup, you can reference the database thru the name you selected.

    Some good articles

    http://www.learnasp.com/learn/dbopen.asp
    http://www.web-savant.com/users/kathi/asp/samples/tut/Database_Connections.asp

    Hope this helps


    quote:Originally posted by gasounet000

    1. Can anyone explain the difference between a DSN versus a DSN-less database connection, and under what circumstances would I use either?

    2. When using the OBDC tool to "Create New Database Connection", what parameter goes in the field "Data Source Name"? I suspect it it the name of my Access dbase but am not certain.

    Thanks

    J. Dyer
    </blockquote id="quote"></font id="quote">
     
  2. There is a slight but measurable degradation of performance with a DSN, or so I've been told.


    quote:Originally posted by bruce

    From a functional standpoint DSN & DSNLess connection is identical. DSN connection uses a System ODBC Data Source to locate your database file. Whereas, DSNLess connection, you specify the location of the database by physical path.

    The ODBC tool create a system ODBC data source, you can use any name you wish. Once you have the DSN setup, you can reference the database thru the name you selected.

    Some good articles

    http://www.learnasp.com/learn/dbopen.asp
    http://www.web-savant.com/users/kathi/asp/samples/tut/Database_Connections.asp

    Hope this helps


    quote:Originally posted by gasounet000

    1. Can anyone explain the difference between a DSN versus a DSN-less database connection, and under what circumstances would I use either?

    2. When using the OBDC tool to "Create New Database Connection", what parameter goes in the field "Data Source Name"? I suspect it it the name of my Access dbase but am not certain.

    Thanks

    J. Dyer
    </blockquote id="quote"></font id="quote">
    </blockquote id="quote"></font id="quote">

    Jon
    (Information doesn't want to be free, it wants to be sixty-nine cents @ pound)
     
  3. 1. Can anyone explain the difference between a DSN versus a DSN-less database connection, and under what circumstances would I use either?

    2. When using the OBDC tool to "Create New Database Connection", what parameter goes in the field "Data Source Name"? I suspect it it the name of my Access dbase but am not certain.

    Thanks

    J. Dyer
     
  4. Check out this information.

    http://www.4guysfromrolla.com/webtech/070399-1.shtml

    I have noticed an increase in performance with large access db's (30,000 records or more) using DSNless as opposed to DSN.

    If you don't have time to read it the biggest difference is that a DSN connection has to read the registry to figure out where the database is. DSNless doesn't.

    Also copy the connection string at the bottom of the page and use the OLEDB layer. :)

    gninthgiLevitaerC
     
Thread Status:
Threads that have been inactive for 5 years or longer are closed to further replies. Please start a new thread.

Share This Page