Results 1 to 2 of 2
  1. #1
    Join Date
    Oct 2008

    Unanswered: ERROR [HY000][DataDirect][ODBC Sybase Wire Protocol driver] Timeout exceeded


    we have an application written in c# which triggers a stored procedure on Sybase. Sometimes, the application throws error as below

    - ERROR [HY000][DataDirect][ODBC Sybase Wire Protocol driver] Timeout exceeded

    - ERROR [HYT00][SYBASE][ODBC Sybase driver][SQL Server]ct_result(): user api layer: internal Client Library error: Read from the server has timed out

    Don't know what's happening here cos the stored procedure might be dying halfway..

    After sometime, if again the stored procedure is called from application, it goes fine.

    If any one know about this error please let me know....


  2. #2
    Join Date
    Aug 2011

    Properly increase CommandTimeout

    probably you are not interested in this problem anymore, but I am replying since I just had the same issue and did not find any solution in the forums.

    I solved the error by setting the CommandTimeout property (default = 30s) to a higher value.

    If you launch the stored procedure by a simple OdbcCommand, setting the CommandTimeout is straightforward.
    If you are using a TableAdapter (for example, if you designed a DataSet with the Visual Studio wizard and set a TableAdapter to launch the stored), you won't access the CommandCollection in your code (it is a protected property of the TableAdapter); so I solved implementing a class which derives from the TableAdapter that the Visual Studio wizard created for me, then in my class constructor I set the CommandTimeout for each Command in the CommandCollection. Finally in my code I don't use the TableAdapter, but my derived class.

    Hope this can help anybody incurring in the same issue.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts