I am using the following function to create a backup of my MySQL Database. This does work great and it generate a .sql file containing everything. The file it
.sql