Name

ELT( )

Synopsis

ELT(number, string,  . . . )

This function returns the number element from the list of remaining arguments given. If the number given is less than one or if the number of elements is less than the number given, this statement will return NULL.

SELECT ELT(2, 'one','two','three')
AS 'ELT( ) Test';
+------------+
| ELT( ) Test |
+------------+
| two        |
+------------+

Get MySQL in a Nutshell now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.