Get started
Load & manage data
Work with data
Administration
Reference & resources
CLUSTER BY
clause (TABLE)mask
clauseROW FILTER
clauseAtualizado 14/02/2025
instr
function Applies to: Databricks SQL
Databricks Runtime
Returns the (1-based) index of the first occurrence of substr
in str
.
> SELECT instr('SparkSQL', 'SQL');
6
> SELECT instr('SparkSQL', 'R');
0
> SELECT instr('SparkSQL' COLLATE UTF8_LCASE, 'sql');
6
> SELECT instr('SparkSQL' COLLATE UTF8_BINARY, 'sql');
6