Skip to main content
Version: V1.0.0

REVERSE

Declaration

REVERSE(str)

Description

Returns the reverse of the string str.

This function is multibyte-safe.

Example

SELECT REVERSE('oceanbase');
+----------------------+
| REVERSE('oceanbase') |
+----------------------+
| esabnaeco |
+----------------------+
1 row in set (0.001 sec)

SELECT REVERSE(1000);
+---------------+
| REVERSE(1000) |
+---------------+
| 0001 |
+---------------+
1 row in set (0.001 sec)