All pages
Powered by GitBook
1 of 1

Loading...

LEFT

Return the leftmost characters. This function returns the specified number of characters from the beginning (left) of a string.

Syntax

LEFT(str,len)

Description

Returns the leftmost len characters from the string str, or NULL if any argument is NULL.

Examples

This page is licensed: GPLv2, originally from

SELECT LEFT('MariaDB', 5);
+--------------------+
| LEFT('MariaDB', 5) |
+--------------------+
| Maria              |
+--------------------+
fill_help_tables.sql