DIFFERENCE

Click to skip syntax diagram
Read syntax diagramSkip visual syntax diagram>>-DIFFERENCE--(--expression-1--,--expression-2--)-------------><
 

The DIFFERENCE function returns a value from 0 to 4 representing the difference between the sounds of two strings based on applying the SOUNDEX function to the strings. A value of 4 is the best possible sound match.

expression-1 or expression-2
The arguments must be a built-in numeric, character-string, or graphic-string data types, but not CLOBs or DBCLOBs. The arguments cannot be binary-strings. A numeric argument is cast to a character string before evaluating the function. For more information on converting numeric to a character string, see VARCHAR.

The data type of the result is INTEGER. If any argument can be null, the result can be null; if any argument is null, the result is the null value.

Examples