Yesterday I got very interesting issue. So When put filter on color, config, style and size. A strange error occur. Filter works for 99% of records but on 1 percent time out occurs. When we dig deep into issue, we found that End user, used the special character ‘(‘ in style. And when we execute the filter on dim of special character reports goes toward timeout. It means some infinite loop occurs.
Our code snippet was
findOrCreateRange_W(query.dataSourceTable(tableNum(InventDim)), fieldNum(InventDim, InventStyleId)).value(InventDimParm.InventStyleId);
Later we found that queryValue is missing in our statement. That was the reason statement was goes into infinite loop.
The correct statement is below as.
findOrCreateRange_W(query.dataSourceTable(tableNum(InventDim)), fieldNum(InventDim, InventStyleId)).value(queryValue(InventDimParm.InventStyleId));