^table.locate[column_name;value_to_be_located]
^table.locate(logical_expression)
^table.locate[column_name;value_to_be_located;options] ^table.locate(logical_expression)[options]
The method locates a specified value in a specified column in the table and returns Boolean value "true/false" depending on whether it found the value or not. In case it locates the specified value, the row where the value is found is set as current. If the value was not located, current row is not shifted.
The second variant of calling method searches first record to conform logical_expression.
Search is case-sensitive.
Example $stuff[^table::create{name pos
Ivanovboss Petrovengineer Lebedev art-director
}]
^if(^stuff.locate[name;Lebedev]){
The entry is found in line ^stuff.line[].<br /> $stuff.name: $stuff.pos<br />
}{
No such entry }
The code will output:
The entry is found in line 3.
Lebedev: art-director