Syntax
Parameters
| Parameter | Description | Supported input types |
|---|---|---|
<substring> | The substring to search for. | TEXT |
<string> | The string that will be searched. | TEXT |
Return Type
INTEGER
Example
1
7
0Reference material for POSITION function
POSITION(<substring> IN <string>)
| Parameter | Description | Supported input types |
|---|---|---|
<substring> | The substring to search for. | TEXT |
<string> | The string that will be searched. | TEXT |
INTEGER
SELECT
POSITION('hello' IN 'hello world') AS res;
1
SELECT
POSITION('world' IN 'hello world') AS res;
7
SELECT
POSITION('work' IN 'hello world') AS res;
0Was this page helpful?