Before falling ill I was working on a really strange problem and I was able to get the solution of it. So, today I am going to share the problem and solution of the problem.

Problem:

After applying some patch on database suddenly we started receiving error on Accounts Screen. On clicking Account List View we received the following error

Error retrieving next record from the database.(SBL-DBC-00104)

The Research:
I did what we usually do to debug these issues. Enabled the logs and logged in through dedicated client and spooled the logs.

What I found out was that a query was being fired in backend that had a extra condition and again Sort Search Optimization was responsible for it but what was strange was, that query was trying to query on a special character which looked like a square. Here is what the query condition looked like

  ((T14.INT_ORG_FLG != ‘Y’ OR T14.PRTNR_FLG = ‘Y’) AND
      (T4.ACCNT_NAME >= :2))
   ORDER BY
      T4.POSITION_ID, T4.ACCNT_NAME
Bind variable 1: 1-6ILGF
Bind variable 2:

[I am sorry but I am not able to produce the square symbol here. Please assume that It is there :) ]

I tried various ways to suppress this condition including the use Sort Search Optimization user property but the error persisted.

More analysis into logs divulged another error.

ORA-24345: A Truncation or null fetch error occurred

Reason:

Searching on support web revealed that this error occurs usually if there is a difference between the BC Field type and physical type. For example

If I create Field of Type DTYPE_BOOL and map it to a column of type VARCHAR with length greater than 1 this error can occur if there is a record in a database that has data in that column which is greater than 1 char.

Solution:

What I found out was really an anti climax and I stumbled upon the answer by accident. The reason was that due a requirement somebody had changed a length of a column in Account BC from 50 to 4 and column underlying had data more than 4 characters resulting in this error.

How I found it out was that accidently I compiled an old version of Account BC after making some changes and problem was solved. Afterwards comparing the new and old version reveled that this column length had been changed.

OkAvarageGoodVery GoodExcellent (2 votes, average: 4.5 out of 5)
Loading ... Loading ...