File Find Error Opening File

From: Smithe Burton (tester_ms_at_hotmail.com)
Date: 06/05/03


Date: Thu, 5 Jun 2003 09:37:59 -0700


I'm trying to access a DB on a remote machine. Its a non
SQL DB. A file Structure type. There is no ONE DB, but
several files for the different tables. I have the
following code that uses an ODBC to access the DB:

********************************************************
string sConnectionString ="Driver={TestTrack ODBC
Driver};Server=(testtrack);DSN=TTPROADXP;UID=;PWD=;";

OdbcConnection objConnection = new OdbcConnection
(sConnectionString);
string sSQL = "SELECT DEFECTS.DEFECTNUM, DEFECTS.SUMMARY,
DEFECTS.DATEENTER FROM DEFECTS" ;
OdbcCommand objCommand = new OdbcCommand
(sSQL,objConnection);

try
{
objCommand.Connection = objConnection;
objConnection.Open();
objDataReader = objCommand.ExecuteReader();

while( objDataReader.Read() )
{
Console.WriteLine (objDataReader("SUMMARY"));
}

}
catch (OdbcException ex)
{
Console.WriteLine (ex.Message);

}
finally
{
objDataReader.Close();
objConnection.Close();
}
********************************************************

This program works fine till objConnection.Open();
but fails on objDataReader = objCommand.ExecuteReader();
giving me error.

"ERROR (S0000) (SYWARE, Inc.)(CODEBASE ODBC Driver)
(CODEBASE)File Find Error Opening File (-64@11)"

I have seen the following posts and tried there
recommendations but to no avail. I also heard something
about .NET 1.1 Framework causing some headache.

>>The error apparently lies in the
>>access to the directory that
>>contains the database. In my
>>case, I was accessing a
>>directory through a mapped drive
>>under different credentials, which failed
>>as that my web runs
>>under ASPNET account.
>
>This is a common issue for
>anything running under the "services"
>account. By default, you
>have admin priveleges for local
>only and *no* network priveleges.
> You need to log
>your service in under a
>specific account, and assign that
>account permissions locally and on
>the network.
>
>Also, mapped drives are not accessible
>unless the user is "logged
>in" -- so for a
>service using a specific account
>you must use UNC paths
>to access network resources.
>
>Hope that helps someone,

I'm not sure what/how to do this.
How do I configure the service for ASPNET?. Basically in
my lamen terms, cause i'm quite green at all this, How to
I set the file permissions on my DB Folder and files to
allow the user, "ASPNET" to read them?..

If I drop my DB to my local machine my code runs fine. As
others have stated above. but as soon as I tweak my ODBC
to point to the REAL remote machines DB folder, I get the
file error.



Relevant Pages

  • Re: W2K/WMI service (WinMgmt.exe) accessing an ODBC connection
    ... credential to be used if those are for a SQL account. ... > The problem I have now is in modifying the ODBC connection. ... >> Starting Win2000, the machine accounts are security principals, ...
    (microsoft.public.win32.programmer.wmi)
  • Re: W2K/WMI service (WinMgmt.exe) accessing an ODBC connection
    ... credential to be used if those are for a SQL account. ... > The problem I have now is in modifying the ODBC connection. ... >> Starting Win2000, the machine accounts are security principals, ...
    (microsoft.public.windows.server.security)
  • Re: LogonUser to remote machine fails with error 1326
    ... enable the guest account or have administrator accounts with matching ... also pass credentials to the remote machine to authenticate which sounds ... note that every user account in Windows is either created on the ...
    (microsoft.public.dotnet.languages.csharp)
  • Re: Unable to connect to DSN
    ... > I finally got tired of dealing with it, so I just used ODBC. ... why do you like OLEDB better? ... There is a great deal of difference: There are two libraries involved when ... I am only using my sa account on my lab rat machine. ...
    (microsoft.public.inetserver.asp.general)
  • Re: exporting data from D3 using ODBC
    ... Also shutdown ODBC server and restart. ... An account is a subdivision of your database for accounting and access issues. ... I have some doubt about the correctness of our parameters because I ...
    (comp.databases.pick)