StringCompareIntl() function - MapBasic - 2023

MapInfo MapBasic Reference

Product type
Software
Portfolio
Locate
Product family
MapInfo
Product
MapInfo > MapBasic
Version
2023
Language
English
Product name
MapBasic
Title
MapInfo MapBasic Reference
First publish date
1985
Last updated
2023-09-12
Published on
2023-09-12T16:32:32.686312

Purpose

Performs language-sensitive string comparisons. You can call this function from the MapBasic window in MapInfo Pro.

Syntax

StringCompareIntl( string1, string2 )

string1 and string2 are the string expressions being compared.

Return Value

SmallInt: -1 if first string precedes second; 1 if first string follows second; zero if strings are equal.

Description

The StringCompareIntl() function performs language-sensitive string comparisons. Call this function if you need to determine the alphabetical order of two strings, and the strings contain characters that are outside the ordinary U.S. character set (for example, umlauts).

The comparison uses whatever language settings are in use on the user's computer. For example, a Windows user can control language settings through the Control Panel.

Return value: When:
-1 first string precedes the second string, using the current language setting
0 the two strings are equal
1 first string follows the second string, using the current language setting

See Also:

Like() function, StringCompare() function