- Instant help with your Sql coding problems

Find MySQL data directory location

Question:
How to find MySQL data directory location?
Answer:
SHOW VARIABLES WHERE Variable_Name = "datadir";
Description:

The datadir MySQL system variable contains the path to the MySQL server data directory. Relative paths are resolved with respect to the current directory. If you expect the server to be started automatically, it is best to specify the datadir value as an absolute path.

Share "How to find MySQL data directory location?"