Icon View Incident Report

Serious Serious
Reported By: Ricardo Oliveira
Reported On: 3/29/2005
For: Version 4.18 Build 1
# 2003 Optimized Partial-Length Searches Using the LIKE Operator Not Returning Correct Results

I'm having a problem with the following query. The results returned are incorrect if "FieldName" is in the primary index of the table.

SELECT * FROM TableName
WHERE FieldName NOT LIKE '01.%' OR FieldName LIKE '01.01.01%'

A workaround for the problem is to use UPPER like this to
force the query to be un-optimized.

SELECT * FROM TableName
WHERE UPPER(FieldName) NOT LIKE UPPER('01.%') OR
FieldName LIKE '01.01.01%'



Comments Comments and Workarounds
The workaround is as described above.


Resolution Resolution
Fixed Problem on 3/30/2005 in version 4.19 build 1


Products Affected Products Affected
DBISAM Additional Software and Utilities
DBISAM ODBC Client-Server
DBISAM ODBC Client-Server with Source
DBISAM ODBC Standard
DBISAM ODBC Standard with Source
DBISAM VCL Client-Server
DBISAM VCL Client-Server with Source
DBISAM VCL Standard
DBISAM VCL Standard with Source

Image