IBM Support

"Query timeout expired ... Object reference not set to an instance of an object" after launching FAP Client

Troubleshooting


Problem

User launches the FAP Client ("FAP Connect"), and logs on (to connect to the FAP database). The system appears to 'hang' for 60 seconds, during which a blank white screen appears. An error appears. After clicking 'continue' the FAP client appears to work. However, if click on the menu item "Logs" a new error appears. User then clicks "Continue", and the FAP client seems to work, but unfortunately there is no information displayed inside the 'logs' section (so therefore the user cannot check if the data is trickling correctly etc.).

Symptom

Initial screen (for the first 60 seconds after launching FAP Connect):


Error after 60 seconds:


    Microsoft .NET Framework
    Unhandled exception has occurred in your application. If you click Continue, the application will ignore this error and attempt to continue. If you click Quit, the application will close immediately.

    Query timeout expired

    [Details] [Continue] [Quit]

    See the end of this message for details on invoking
    just-in-time (JIT) debugging instead of this dialog box.

    ************** Exception Text **************
    System.Data.OleDb.OleDbException: Query timeout expired
    at System.Data.OleDb.OleDbDataReader.ProcessResults(OleDbHResult hr)
    at System.Data.OleDb.OleDbDataReader.NextResult()
    at System.Data.OleDb.OleDbCommand.ExecuteReaderInternal(CommandBehavior behavior, String method)
    at System.Data.OleDb.OleDbCommand.ExecuteReader(CommandBehavior behavior)
    at System.Data.OleDb.OleDbCommand.System.Data.IDbCommand.ExecuteReader(CommandBehavior behavior)
    at System.Data.Common.DbDataAdapter.FillInternal(DataSet dataset, DataTable[] datatables, Int32 startRecord, Int32 maxRecords, String srcTable, IDbCommand command, CommandBehavior behavior)
    at System.Data.Common.DbDataAdapter.Fill(DataSet dataSet, Int32 startRecord, Int32 maxRecords, String srcTable, IDbCommand command, CommandBehavior behavior)
    at System.Data.Common.DbDataAdapter.Fill(DataSet dataSet)
    at FAPClient.FAP.Dao.LogDao.SearchItems(Context& ctx, LogSortColumn sortBy, LogSortOrder sortOrder, Int32 pageNumber, Int32 pageSize, LogObjectType typeFilter, String& objectFilter, LogSeverity severityFilter)
    at FAPClient.frmDefine.RefreshLog()
    at FAPClient.frmDefine.Connect()
    at FAPClient.frmDefine.frmMain_Load(Object sender, EventArgs e)
    at System.EventHandler.Invoke(Object sender, EventArgs e)
    at System.Windows.Forms.Form.OnLoad(EventArgs e)
    at System.Windows.Forms.Form.OnCreateControl()
    at System.Windows.Forms.Control.CreateControl(Boolean fIgnoreVisible)
    at System.Windows.Forms.Control.CreateControl()
    at System.Windows.Forms.Control.WmShowWindow(Message& m)
    at System.Windows.Forms.Control.WndProc(Message& m)
    at System.Windows.Forms.ScrollableControl.WndProc(Message& m)
    at System.Windows.Forms.ContainerControl.WndProc(Message& m)
    at System.Windows.Forms.Form.WmShowWindow(Message& m)
    at System.Windows.Forms.Form.WndProc(Message& m)
    at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
    at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
    at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)


    ************** Loaded Assemblies **************
    mscorlib
    Assembly Version: 2.0.0.0
    Win32 Version: 2.0.50727.5466 (Win7SP1GDR.050727-5400)
    CodeBase: file:///C:/Windows/Microsoft.NET/Framework/v2.0.50727/mscorlib.dll
    ----------------------------------------
    FAPClient
    Assembly Version: 1.0.13.0
    Win32 Version: 1.0.13.0
    CodeBase: file:///C:/Program%20Files%20(x86)/ibm/cognos/c10/webcontent/ccr/FAPClient.exe
    ----------------------------------------
    Microsoft.VisualBasic
    Assembly Version: 8.0.0.0
    Win32 Version: 8.0.50727.5420 (Win7SP1.050727-5400)
    CodeBase: file:///C:/Windows/assembly/GAC_MSIL/Microsoft.VisualBasic/8.0.0.0__b03f5f7f11d50a3a/Microsoft.VisualBasic.dll
    ----------------------------------------
    System
    Assembly Version: 2.0.0.0

After clicking "Logs":

Microsoft .NET Framework
Unhandled exception has occurred in your application. If you click Continue, the application will ignore this error and attempt to continue. If you click Quit, the application will close immediately.

Object reference not set to an instance of an object.

[Details] [Continue] [Quit]

See the end of this message for details on invoking
just-in-time (JIT) debugging instead of this dialog box.

************** Exception Text **************
System.NullReferenceException: Object reference not set to an instance of an object.
at FAPClient.frmDefine.LogGridView_MouseMove(Object sender, MouseEventArgs e)
at System.Windows.Forms.Control.OnMouseMove(MouseEventArgs e)
at C1.Win.C1FlexGrid.C1FlexGridBase.OnMouseMove(MouseEventArgs e)
at System.Windows.Forms.Control.WmMouseMove(Message& m)
at System.Windows.Forms.Control.WndProc(Message& m)
at C1.Win.C1FlexGrid.Util.BaseControls.ScrollableControl.WndProc(Message& m)
at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)


************** Loaded Assemblies **************
mscorlib
Assembly Version: 2.0.0.0
Win32 Version: 2.0.50727.5466 (Win7SP1GDR.050727-5400)
CodeBase: file:///C:/Windows/Microsoft.NET/Framework/v2.0.50727/mscorlib.dll
----------------------------------------
FAPClient
Assembly Version: 1.0.13.0
Win32 Version: 1.0.13.0
CodeBase: file:///C:/Program%20Files%20(x86)/ibm/cognos/c10/webcontent/ccr/FAPClient.exe

Cause

FAP datamart database contains invalid data.

  • Specifically, in one real-life case the 'log' table was too large.

More Information
When the FAP client starts it does the following:
1. Logs on to the FAP 'data mart' database (i.e. not the 'Controller' application repository database)
2. Reads settings from the table: NRTR_SETUP
3. Reads Source settings from the table: NRTR_SOURCE
4. Reads Datamart settings from the table: NRTR_DATAMART
5. Reads log entries from the table: NRTR_LOG

In a real-life customer's case, the final step (reading the LOG table) was the one that times out.
  • In that case, the customer's log table had a huge number (497,630) of records.

Resolving The Problem

Truncate the table "NRTR_LOG" inside the FAP database.

Steps:

  1. Ensure that all users are not using the FAP client (downtime)
  2. As a precaution, crate a backup of the "FAP" database
  3. Run the following SQL script on the database:
      truncate table dbo.NRTR_LOG

TIP: This script assumes that the table owner is 'dbo'.
  • You may need to change this to a different user (e.g. "fastnet") depending on your configuration.

[{"Product":{"code":"SS9S6B","label":"IBM Cognos Controller"},"Business Unit":{"code":"BU059","label":"IBM Software w\/o TPS"},"Component":"Controller","Platform":[{"code":"PF033","label":"Windows"}],"Version":"10.1.1","Edition":"","Line of Business":{"code":"LOB10","label":"Data and AI"}}]

Document Information

Modified date:
15 June 2018

UID

swg21633758