Resolve error when comparing two non-printable characters in MapBasic 64-bit

Products affected: MapInfo Pro™ 64-bit, MapBasic® 64-bit


If you run the following statement within MapBasic® 32-bit / MapInfo Professional® 32-bit you will receive a False outcome:
Indicating that the characters are not alike.

However, if you run this within MapBasic 64-bit / MapInfo Pro™ 64-bit you will receive a True outcome.


This is a system limitation and is currently working as designed.


UPDATED: December 5, 2019
In Unicode MapInfo Pro, the MapBasic equals-operator uses a Unicode normalization and collation scheme for comparing string values. In this scheme, there is no order difference between non-printable characters.

For binary data comparisons, the MapBasic StringCompare function should be used, rather than the equals-operator, as StringCompare performs a byte-comparison, not a normalized string comparison.

For example:
StringCompare(Chr$(1), Chr$(2))

will return -1