Argument | Required/ Optional | Description |
---|---|---|
string | Required | The string must be a character string. Passes the value you want to evaluate. You can enter any valid expression. The results of the expression must be a character string. If not, INSTR converts the value to a string before evaluating it. |
search_value | Required | Any value. The search value is case sensitive. The set of characters you want to search for. The search_value must match a part of the string. For example, if you write INSTR('Alfred Pope', 'Alfred Smith') the function returns 0. You can enter any valid expression. If you want to search for a character string, enclose the characters you want to search for in single quotation marks, for example 'abc'. |
start | Optional | Must be an integer value. The position in the string where you want to start the search. You can enter any valid expression. The default is 1, meaning that INSTR starts the search at the first character in the string. If the start position is 0, INSTR searches from the first character in the string. If the start position is a positive number, INSTR locates the start position by counting from the beginning of the string. If the start position is a negative number, INSTR locates the start position by counting from the end of the string. If you omit this argument, the function uses the default value of 1. |
occurrence | Optional | A positive integer greater than 0. You can enter any valid expression. If the search value appears more than once in the string, you can specify which occurrence you want to search for. For example, you would enter 2 to search for the second occurrence from the start position. If you omit this argument, the function uses the default value of 1, meaning that INSTR searches for the first occurrence of the search value. If you pass a decimal, Data Integration rounds it to the nearest integer value. If you pass a negative integer or 0, the mapping fails when you run a workflow. |
COMPANY | RETURN VALUE |
---|---|
Blue Fin Aqua Center | 13 |
Maco Shark Shop | 2 |
Scuba Gear | 5 |
Frank's Dive Shop | 3 |
VIP Diving Club | 0 |
COMPANY | RETURN VALUE |
---|---|
Blue Fin Aqua Center | 0 |
Maco Shark Shop | 8 |
Scuba Gear | 9 |
Frank's Dive Shop | 0 |
VIP Diving Club | 0 |
COMPANY | RETURN VALUE |
---|---|
Blue Fin Aqua Center | 0 |
Maco Shark Shop | 2 |
Scuba Gear | 5 |
Frank's Dive Shop | 0 |
VIP Diving Club | 0 |
COMPANY | RETURN VALUE |
---|---|
Blue Fin Aqua Center | 1 |
Maco Shark Shop | 0 |
Scuba Gear | 0 |
Frank's Dive Shop | 0 |
VIP Diving Club | 0 |
CUST_NAME | RETURN VALUE |
---|---|
PATRICIA JONES | PATRICIA |
MARY ELLEN SHAH | MARY ELLEN |
CUST_ID | RETURN VALUE |
---|---|
ID#33 | ID33 |
#A3577 | A3577 |
SS #712403399 | SS 712403399 |