Please be aware that the content in SAP SQL Anywhere Forum will be migrated to the SAP Community in June and this forum will be retired.

We have an application built in C# connecting to a Sybase 6.0.0.4789 and sql anywhere 11.1.2596 For sometime the application runs fine reading the text files and creates/updates/insert data into the tables without any problem. After sometime the application throws an error .The exception I get is ERROR [08001][Sybase][ODBC Driver][SQL Anywhere]Database server not found.

The connection string I'm using is if (sqlString != string.Empty) { oDBHelper.ExecuteNonQuery(CommandType.Text, sqlString); sb = new StringBuilder(); sqlString = string.Empty; }

execute non query to open and insert data

public int ExecuteNonQuery(CommandType cmdType, string cmdText) { try {

        EstablishFactoryConnection();
        PrepareCommand(false, cmdType, cmdText);
        int val = oCommand.ExecuteNonQuery();
        return val;
}

Below is the connection to open database.

public void EstablishFactoryConnection() { if (0 == DbProviderFactories.GetFactoryClasses().Select("InvariantName='" + S_PROVIDER + "'").Length) throw new Exception("Invalid Provider"); / oConnection = oFactory.CreateConnection();

    if (oConnection.State == ConnectionState.Closed)
    {
        if (utils != null)
        {
           oConnection.ConnectionString = utils.DBMgr.ConnectionStr;
           oConnection.Open();
           oConnectionState = ConnectionState.Open;
        }
    }
}

But when tested on another server which has sybase 6.0.0.4787 and sql anywhere 11.0.1 the application works perfectly alright without any issues. Creates all the tables and inserts the data through the application . Is this anyway related to the version's of the sybase and sql anywhere . NOt sure whats happening. Any ideas? and Please help me in this regard am really helpless at this point of time.

Thanks in advance

asked 22 Aug '13, 11:59

Satish%20Panithi's gravatar image

Satish Panithi
91447
accept rate: 0%

When you say "sybase 6.0.0.4787" do you mean Sybase Central? That is a utility which has nothing to do with how your application connects to the database.

Please post the actual connection string; what you have posted is some application code that may or may not be referring to the connection string, we have no way of telling.

If you are using a framework you may have to dig down to find out what is actually going on... good luck!

(22 Aug '13, 17:19) Breck Carter

But when tested on another server which has sybase 6.0.0.4787 and sql anywhere 11.0.1 the application works perfectly alright without any issues. Creates all the tables and inserts the data through the application . Is this anyway related to the version's of the sybase and sql anywhere .

Which specific build version of SQL Anywhere 11.0.1 is installed on the system that currently works? Is it the same database, data and tables in both cases?

Have you tried installing an EBF on the problematic installation to see if this problem is indeed fixed in a later build?

(23 Aug '13, 08:12) Jeff Albion
Be the first one to answer this question!
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:

×128

question asked: 22 Aug '13, 11:59

question was seen: 6,828 times

last updated: 23 Aug '13, 08:12