Sybase DB access in windows 7
-
Hi all I am using .net FW 3.5, its desktop applicaiton. MyApplication is fetching data from sybase adoptive server and populating in it. Below connection, code.
connectionString=DRIVER=MERANT 3.60 32-BIT Sybase;UID=test;DB=db1;SRVR=XYZSERVER;PWD=*****
using (OdbcConnection connection = new OdbcConnection(connStringFromConfig)
{
OdbcDataAdapter adapter = new OdbcDataAdapter(query, onnection);
connection.Open();
adapter.Fill(dt);
connection.Close();
}above code works fine in windows xp. where as same code is not working in windows 7. I am executing in 64bit machine. i got error while opening connection.
ERROR [IM002] [Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified
Anything i am missing ? or do i need to configure anything? appriciated u r quick response.
Ramana
-
Hi all I am using .net FW 3.5, its desktop applicaiton. MyApplication is fetching data from sybase adoptive server and populating in it. Below connection, code.
connectionString=DRIVER=MERANT 3.60 32-BIT Sybase;UID=test;DB=db1;SRVR=XYZSERVER;PWD=*****
using (OdbcConnection connection = new OdbcConnection(connStringFromConfig)
{
OdbcDataAdapter adapter = new OdbcDataAdapter(query, onnection);
connection.Open();
adapter.Fill(dt);
connection.Close();
}above code works fine in windows xp. where as same code is not working in windows 7. I am executing in 64bit machine. i got error while opening connection.
ERROR [IM002] [Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified
Anything i am missing ? or do i need to configure anything? appriciated u r quick response.
Ramana
The coding part is completely correct, file connection is open and closed also. I guess window 7 does not support this function. best face cleanser