Wrox Home  
Search P2P Archive for: Go

  Return to Index  

asp_databases thread: DSN Problem


Message #1 by "dale Borchardt" <dale@d...> on Mon, 12 Aug 2002 15:38:00
All of a sudden I am getting the error

"Error Type:
Microsoft OLE DB Provider for ODBC Drivers (0x80004005)
[Microsoft][ODBC Microsoft Access Driver] 'E:\MHHC Public\MHHC IT 
Management\MHHC IT Management.mdb' is not a valid path. Make sure that 
the path name is spelled correctly and that you are connected to the 
server on which the file resides."

This would be fine if this were the DSN I was trying to get at. No matter 
wat I do for my DSN I get this error. Something somewhere seems to be 
stuck. The DSN this error points to is a valid data source but it has 
been set on the server and for another app. I am trying to start a new 
project and use a DSN on my local machine and use a different name for 
the DSN, and still I get this error.
  All of my online apps work, it is only develpement I am having problems 
with.
PC os XP pro
I am using Visual interdev as my editor

Thanks
Message #2 by "Gavin Landon" <glandon@g...> on Mon, 12 Aug 2002 15:57:36 -0500
I would highly suggest moving away from DSN's..   They use ODBC and are
slower than using OLEDB and a connection string.


"dale Borchardt" <dale@d...> wrote in message
news:203656@a..._databases...
>
> All of a sudden I am getting the error
>
> "Error Type:
> Microsoft OLE DB Provider for ODBC Drivers (0x80004005)
> [Microsoft][ODBC Microsoft Access Driver] 'E:\MHHC Public\MHHC IT
> Management\MHHC IT Management.mdb' is not a valid path. Make sure that
> the path name is spelled correctly and that you are connected to the
> server on which the file resides."
>
> This would be fine if this were the DSN I was trying to get at. No matter
> wat I do for my DSN I get this error. Something somewhere seems to be
> stuck. The DSN this error points to is a valid data source but it has
> been set on the server and for another app. I am trying to start a new
> project and use a DSN on my local machine and use a different name for
> the DSN, and still I get this error.
>   All of my online apps work, it is only develpement I am having problems
> with.
> PC os XP pro
> I am using Visual interdev as my editor
>
> Thanks
>
>


Message #3 by "dale Borchardt" <dale@d...> on Tue, 13 Aug 2002 19:32:38
Please tell me more. I think I am on the same page; are you talking about 
a DSN-less connection? I have been stuck in the same rutt for 3 years now 
and Im sure there is a better way.


> I would highly suggest moving away from DSN's..   They use ODBC and are
slower than using OLEDB and a connection string.


"dale Borchardt" <dale@d...> wrote in message
news:203656@a..._databases...
>
> All of a sudden I am getting the error
>
> "Error Type:
> Microsoft OLE DB Provider for ODBC Drivers (0x80004005)
> [Microsoft][ODBC Microsoft Access Driver] 'E:\MHHC Public\MHHC IT
> Management\MHHC IT Management.mdb' is not a valid path. Make sure that
> the path name is spelled correctly and that you are connected to the
> server on which the file resides."
>
> This would be fine if this were the DSN I was trying to get at. No 
matter
> wat I do for my DSN I get this error. Something somewhere seems to be
> stuck. The DSN this error points to is a valid data source but it has
> been set on the server and for another app. I am trying to start a new
> project and use a DSN on my local machine and use a different name for
> the DSN, and still I get this error.
>   All of my online apps work, it is only develpement I am having 
problems
> with.
> PC os XP pro
> I am using Visual interdev as my editor
>
> Thanks
>
>


Message #4 by "Ken Schaefer" <ken@a...> on Wed, 14 Aug 2002 11:06:28 +1000
DSN and DSN-less connections both use ODBC. A DSN stores the ODBC connection
parameters in the registry, and a DSN-less connection provides the
parameters (eg what driver to use, where the database is located etc) in the
connection string.

So, an Access DSN-less connection string would look like:
Driver={Microsoft Access Driver (*.mdb)};Dbq=c:\somepath\mydb.mdb;UID=Admin

An OLEDB connection string uses an OLEDB Provider, and would look like:
Provider=Microsoft.Jet.OLEDB.4.0;Data Source=c:\somepath\mydb.mdb

Check out:
http://www.able-consulting.com/ado_conn.htm
for the necessary connection string for your database.

Cheers
Ken

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
From: "dale Borchardt" <dale@d...>
Subject: [asp_databases] Re: DSN Problem


: Please tell me more. I think I am on the same page; are you talking about
: a DSN-less connection? I have been stuck in the same rutt for 3 years now
: and Im sure there is a better way.

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Message #5 by bharatbindage@h... on Wed, 14 Aug 2002 05:04:02
> DSN and DSN-less connections both use ODBC. A DSN stores the ODBC 
connection
parameters in the registry, and a DSN-less connection provides the
parameters (eg what driver to use, where the database is located etc) in 
the
connection string.

So, an Access DSN-less connection string would look like:
Driver={Microsoft Access Driver 
(*.mdb)};Dbq=c:\somepath\mydb.mdb;UID=Admin

An OLEDB connection string uses an OLEDB Provider, and would look like:
Provider=Microsoft.Jet.OLEDB.4.0;Data Source=c:\somepath\mydb.mdb

Check out:
http://www.able-consulting.com/ado_conn.htm
for the necessary connection string for your database.

Cheers
Ken

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
From: "dale Borchardt" <dale@d...>
Subject: [asp_databases] Re: DSN Problem


: Please tell me more. I think I am on the same page; are you talking 
about
: a DSN-less connection? I have been stuck in the same rutt for 3 years 
now
: and Im sure there is a better way.

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Hi Ken,
I also got a problem with DSN to access a MSACCESS mdb with password,
when i set 
Session("connectstring")="DSN=INTERNALCOSTING;UID=ADMIN;PWD=PASSWD"

It gives me error saying that "invalid password".
Actually My password is not user level it is database level.
When i use dsn less string i get connected easily.

cst="Provider=Microsoft.Jet.OLEDB.4.0;Data 
Source=c:/sample/tryit/tryit_local/database/projectcosting.mdb"
cst=cst & ";Persist Security Info=False;Jet OLEDB:Database 
Password=passwd"
Session("ConnectString") = cst
it works in this case, but how can i give database level password WITH DSN


  Return to Index