Few times I heard from MySQL users, customers and Sales consultants about their wish to have SQL command, allowing to backup MySQL server. I asked why calling mysqbackup or mysqldump does not work for them and these people had reasons. One of them is security: this way you don't need to give shell access to MySQL server for the person who is supposed to do backup.
MySQL does not have such a command, except for MySQL Cluster. There are instead multiple programs which can make backup if run externally, such as mysqlbackup of mysqldump.
That time I wrote a UDF which runs any external command (https://github.com/svetasmirnova/run_external). So customers could run something similar to:
mysql> SELECT …