Accessing a sybase anywhere 5.0 server 
Author Message
 Accessing a sybase anywhere 5.0 server

I am trying to write I web-user interface that can make queries against a
Sybase Anywhere 5.0 Database. On the test setup, the Database server will
and IIS will be running on the same machine. My problem lies when I try to
make I connection to the database.

string strConnection="DSN=USData";

string strSelect="SELECT * FROM bl";

OdbcConnection odbcConnection=new OdbcConnection(strConnection);

OdbcCommand odbcCommand=new OdbcCommand(strSelect,odbcConnection);

OdbcDataAdapter odbcDataAdapter=new OdbcDataAdapter(odbcCommand);

odbcConnection.Open();

I get this error:

ERROR [08001] [Sybase][ODBC Driver]Unable to connect to database server:
unable to start database engine ERROR [01000] [Microsoft][ODBC Driver
Manager] The driver doesn't support the version of ODBC behavior that the
application requested (see SQLSetEnvAttr).

But from the server i can start sybase central with no problem using the
same settings as in the system-dsn USData.

Thanks much for any insight you might have,

Nathan Going



Tue, 21 Dec 2004 20:05:31 GMT  
 Accessing a sybase anywhere 5.0 server
Hi Nathan

    I had a similar problem, for what I saw it is a problem with dbclient
and ASP .NET, dbclient will refuse to get up when you open a connection from
ASP .NET if it is already up from other place(like sccentral), also if u
don't configure the options part in the dsn and leave the default (dbeng50)
it won't work either, I have a Sybase Anywhere 5.5 up and running with ASP
.NET. Try the following:

1.-First start up a server using the server manager or manually using
dbsrv50.exe
2.-Make the odbc DSN for ASP .NET (be carefull in the server name as it is
case sensitive), don't forget to press the options button, and in there
specify to use dbclient, use this DSN with ASP .NET ONLY
3.-Make a second ODBC, but in this case leave options at it came by default
(dbeng50), use this DSN with all EXCEPT ASP .NET

This do the trick in my case with 5.5, which is pretty the same thing

I hope this helps, and feel free to contact me if u need more assistance

Fernando
Another one suffering Sybase lol


Quote:
> I am trying to write I web-user interface that can make queries against a
> Sybase Anywhere 5.0 Database. On the test setup, the Database server will
> and IIS will be running on the same machine. My problem lies when I try to
> make I connection to the database.

> string strConnection="DSN=USData";

> string strSelect="SELECT * FROM bl";

> OdbcConnection odbcConnection=new OdbcConnection(strConnection);

> OdbcCommand odbcCommand=new OdbcCommand(strSelect,odbcConnection);

> OdbcDataAdapter odbcDataAdapter=new OdbcDataAdapter(odbcCommand);

> odbcConnection.Open();

> I get this error:

> ERROR [08001] [Sybase][ODBC Driver]Unable to connect to database server:
> unable to start database engine ERROR [01000] [Microsoft][ODBC Driver
> Manager] The driver doesn't support the version of ODBC behavior that the
> application requested (see SQLSetEnvAttr).

> But from the server i can start sybase central with no problem using the
> same settings as in the system-dsn USData.

> Thanks much for any insight you might have,

> Nathan Going



Sun, 20 Feb 2005 11:56:29 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. Accessing a sybase anywhere 5.0 server

2. Accessing a sybase anywhere 5.0 server

3. GetBookmark w/ Sybase Anywhere 5.0

4. C++ Library for database access (Oracle, SQL Server, DB2, Sybase, Informix, InterBase, SQLBase and ODBC)

5. CDaoTableDef.GetIndexInfo fails with ODBC Sybase SQL Anywhere

6. CDaoRecordset.AddNew() fails with ODBC Sybase SQL Anywhere

7. How about Sybase SQL Anywhere?

8. CDaoRecordset.AddNew() fails with ODBC Sybase SQL Anywhere

9. VC 5.0 Enterprise Edition & Sybase

10. Adaptive Server Anywhere LONG BINARY problem

11. CDaoDatabase to connect to Adaptive Server Anywhere 6.0

12. Sybase Open Server (Passing Parameters/Pointers)

 

 
Powered by phpBB® Forum Software