1864287 - During CommandTimeout, Exception thrown: UnhandledException: System.NullReferenceException: Object reference not set to an instance of an object | SAP Knowledge Base Article

SAP Knowledge Base Article - Preview

1864287 - During CommandTimeout, Exception thrown: UnhandledException: System.NullReferenceException: Object reference not set to an instance of an object

Symptom

  • CommandTimeout causing Exceptions using ASE ADO.NET Data Provider
  • Exception: System.InvalidOperationException: Cannot execute a command without opening the Connection
  • Unhandled Exception: System.NullReferenceException: Object reference not set to an instance of an object
  • In some cases an active transaction exists on the ASE database which can lock the resource, such as a table. This will occur when CommandTimeout occurs (Error" "The command has timed out"). The application Connection status is marked Open but the connection is disconnected form the ASE
  • In all cases, as mentioned, ADO.NET Connection status is marked as Open but the physical connection to SAP Sybase ASE is disconnected

Read more...

Environment

  • SDK 15.7 (Software Develop Kit)
  • ASE ADO.NET Data Provider 2.0 and 4.0
  • SAP Sybase ASE 15.7
  • Visual Studio 2008/2010
  • Microsoft .NET Framework 2.0 to 4.0
  • Developed in C#, VB.NET
  • Windows 7, 2008, 2008 R2 x64 (can also happen with Windows XP x86/x64)

Product

SAP Adaptive Server Enterprise 15.7

Keywords

ADO.NET transaction AseConnection.Status Open adodotnet ADODOTNET , KBA , BC-SYB-SDK , SDK , Bug Filed

About this page

This is a preview of a SAP Knowledge Base Article. Click more to access the full version on SAP ONE Support launchpad (Login required).

Search for additional results

Visit SAP Support Portal's SAP Notes and KBA Search.