Document toolboxDocument toolbox

Edit distance: Damerau (damerau)

Description

Creates a new column that returns the Damerau edit distance between two strings.

How does it work in the search window?

Select Create field in the search window toolbar, then select the Edit distance: Damerau operation. You need to specify two arguments:

Argument

Data type

Argument

Data type

String mandatory

string

String mandatory

string

The data type of the values in the new field is integer.

Example

In the demo.ecommerce.data table, we want to know the Damerau distance between the strings in the referralUri and uri field. To do it, we will create a new field using the Edit distance: Damerau operation.

The arguments needed to create the new column are:

  • String - referralUri field

  • String - uri field

Click Create column and you will see the following result:

How does it work in LINQ?

Use the operator select... as...  and add the operation syntax to create the new column. This is the syntax for the Edit distance: Damerau operation:

  • damerau(string1, string2)

Example

You can copy the following LINQ script and try the above example on the demo.ecommerce.data table:

from demo.ecommerce.data select damerau(referralUri, uri) as damerau