Simon Fromme filename-safe conversion of database-/tablenames
Aug 09, 2016; 18:13
Simon Fromme
filename-safe conversion of database-/tablenames
Hello,
In order to do MySQL-dumps to a file on a Linux system under
$BACKUP_DIR/$DB_NAME/$TABLE_NAME.sql
I need to convert both the names of databases and tables in a filename-safe way (escaping "/" and other characters as in [1]). The mapping of MySQL database/table name to the according filenames should preferably be the same that MySQL (or the particular DB engine) uses. If that's not possible the mapping should at least be injective and preferably be human readable.
I found out that MySQL is using the C-function tablename_to_filename(...) [2] internally but didn't find a way in which it exposes this conversion function to the outside.
Did I overlook some way this could be done? If not, would this be a feature that a future version of MySQL should provide?
-- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe: http://lists.mysql.com/mysql
Aug 11
Johan De Meersman Re: filename-safe conversion of database-/tablenames
Aug 11, 2016; 15:25
Johan De Meersman
Re: filename-safe conversion of database-/tablenames
Search
Lasso Programming
This site manages and broadcasts several email lists pertaining to Lasso Programming and technologies related and used by Lasso developers. Sign up today!