Logical and Conditional Functions - MapInfo_Pro_Advanced - 2023

MapInfo Pro Advanced Help

Product type
Software
Portfolio
Locate
Product family
MapInfo
Product
MapInfo > MapInfo Pro
Version
2023
ft:locale
en-US
Product name
MapInfo Pro Advanced
ft:title
MapInfo Pro Advanced Help
First publish date
2016
ft:lastEdition
2023-09-20
ft:lastPublication
2023-09-20T15:00:50.875000

You can use the conditional functions to return one value if a condition you specify evaluates to TRUE, and another value if it evaluates to FALSE.

Table 1. Logical and conditional functions
Function Meaning Example
cond(condition,x,y) If condition is true, then value is x else value is y cond(Input_1> null,Input_1+1000,Input_1-1000)
If condition Then x Else y Endif If condition is true, then value is x else value is y If (Input_1=600) Then Input_1 Else Input_1*2 Endif
not(a) Logical not operator. not(Input_1 = 100)
xor(a,b) Logical xor operator (exclusive of a and b) xor(Input_1 >0, Input_2 <20000)
ANY Match against a collection/range of values cond(Any(Input_1, 22, 100, 200..300, 500:600) , Input_1, null)