IBM Support

"Microsoft Visual C++ Debug Library ... Debug Assertion Failed! ... Expression: length < sizeInTChars" when running Report

Troubleshooting


Problem

User launches Controller. User clicks 'Reports - Run' and selects a report. User enters the parameters and clicks on the 'Preview' icon. User receives error message. Problem affects only one (or some) report(s).

Symptom

First error:

Microsoft Visual C++ Debug Library


Debug Assertion Failed!
Program: C:\Program Files\Microsoft Office\OFFICE11\EXCEL.EXE
File: f:\rtm\vctools\crt_bld\self_x86\crt\src\xtoa.c
Line: 142
Expression: length < sizeInTChars
For information on how your program can cause an assertion failure, see the Visual C++ documentation on asserts.
(Press Retry to debug the application)
Abort Retry Ignore

If click 'Abort', get another message:

Information
Standard Error
Number: -2147023170
Source: Microsoft.VisualBasic
Description: The remote procedure call failed. (Exception from HRESULT: 0x800706BE)

Cause

TIP: The error "Debug Assertion Failed!" is generic. Therefore, there are several potential causes for the similar error messages. See separate IBM Technote #1396223 for more examples.

This IBM Technote specifically deals with the scenario where the cause is invalid controller formula used in insert columns.

In one customer's case, the error was caused by column E, where client use:
E33=cc.fAcc(F33)

This is then referenced to:
F33=cc.fGetVal($C$2,"P001","YTD",$C$5,$C$7,"AP"," ",$C$11,"109000"," "," "," "," "," ",$C$19,$C$20," ","F","",""," ","0")

Resolving The Problem

Regenerate layout and make sure the report has no error, then insert customer column, save and test layout

Steps:

  1. Click "Reports - Create"
  2. Use the 'save as' button to save the report as a new report (for example 'test')
  3. Use 'save as' button to make a copy of column and row definition.
  4. Regenerate layout for the test report
  5. Use 'Report - Run' to test the new report
  6. If the error does not occur for the test report, start to add in the extra 'customized' formula.

[{"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":"8.3","Edition":"Not Applicable","Line of Business":{"code":"LOB10","label":"Data and AI"}}]

Historical Number

1042195

Document Information

Modified date:
15 June 2018

UID

swg21367464