This MariaDB tutorial explains how to use the MariaDB SUBSTRING_INDEX function with syntax and examples.
The MariaDB SUBSTRING_INDEX function returns the substring of string before number of occurrences of delimiter.
The syntax for the SUBSTRING_INDEX function in MariaDB is:
The source string.
The delimiter to search for in string.
The number of times to search for delimiter.
The SUBSTRING_INDEX function can be used in the following versions of MariaDB:
Let's look at some MariaDB SUBSTRING_INDEX function examples and explore how to use the SUBSTRING_INDEX function in MariaDB.
For example: