MySQL simple question: CREATE SCHEMA using a custom location

zgilboa used Ask the Experts™

what parameters should I include in a CREATE SCHEMA statement in order to create a MySql database using a custom location, that is, using a folder that is not under the 'data' folder that is indicated in the startup variables?

Thanks in advance,
Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®
There is no such option in MySQL 5.5 reference. All databases are created in data folder and even more, if you create a folder in data folder it will appear as a database when you do 'show databases'.

I've never done it but you may try creating a database in a normal way, than moving the folder somewhere else and in the data folder creating a link pointing to the new location.

Do more with

Expert Office
Submit tech questions to Ask the Experts™ at any time to receive solutions, advice, and new ideas from leading industry professionals.

Start 7-Day Free Trial