How can I connect to a remote database?

D

Dave F.

I am using ODBC to connect to dBase data on a remote server. The ASP.NET app
will be running on Win 2k or 2003 server. I have tried to make it work but
all I can get is an error.

System.Data.Odbc.OdbcException: ERROR [HY024] [Microsoft][ODBC dBase Driver]
'(unknown)' 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. ERROR [IM006] [Microsoft][ODBC Driver Manager] Driver's
SQLSetConnectAttr failed ERROR [HY024] [Microsoft][ODBC dBase Driver]
'(unknown)' 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.

Everything works fine if the data and the .net app are on the same machine
but won't work if separated.

I'm using the DSN. The driver is Microsoft dBase driver. Any ideas besides
changing to OleDB?

Thanks
 
K

Kevin Spencer

Hi Dave,

The problem is that you're not trying to connect to a database server, such
as SQL Server, Oracle, or MySQL. You're trying to connect over a network to
a file-based database.

--
HTH,

Kevin Spencer
Microsoft MVP
..Net Developer
Sometimes you eat the elephant.
Sometimes the elephant eats you.
 
B

Bruce Barker

the asp.net process does not have network permission by default, so the
driver can not access the share. on you 2003 server, create an app pool with
a domain account, with permissions to the share, and setup your site to use
the app pool. on win2k, use the <identity> section in web.config to set a
domain account

-- bruce (sqlwork.com)
 
D

Dave F.

Bruce,

Thanks for the help. I think we are on to something now. Our SQL database is
about a year away. I'm sure that will make life much easier.

Dave

Bruce Barker said:
the asp.net process does not have network permission by default, so the
driver can not access the share. on you 2003 server, create an app pool
with a domain account, with permissions to the share, and setup your site
to use the app pool. on win2k, use the <identity> section in web.config to
set a domain account

-- bruce (sqlwork.com)


Dave F. said:
I am using ODBC to connect to dBase data on a remote server. The ASP.NET
app will be running on Win 2k or 2003 server. I have tried to make it work
but all I can get is an error.

System.Data.Odbc.OdbcException: ERROR [HY024] [Microsoft][ODBC dBase
Driver]
'(unknown)' 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. ERROR [IM006] [Microsoft][ODBC Driver Manager] Driver's
SQLSetConnectAttr failed ERROR [HY024] [Microsoft][ODBC dBase Driver]
'(unknown)' 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.

Everything works fine if the data and the .net app are on the same
machine but won't work if separated.

I'm using the DSN. The driver is Microsoft dBase driver. Any ideas
besides changing to OleDB?

Thanks
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,992
Messages
2,570,220
Members
46,807
Latest member
ryef

Latest Threads

Top