- Trending Categories
- Data Structure
- Operating System
- C Programming
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
MySQL Command-Line Options that Affect Option-File Handling
Let us understand how MySQL command line options affect option file handling −
Many of the MySQL programs which support option files handle the below options. Since these options affect option-file handling, they must be provided on the command line and not in an option ile. For it to work properly, each of these options must be provided before other options, with the below mentioned exceptions −
−−print−defaults should be used immediately after −−defaults−file, −−defaults−extra−file, or −−loginpath.
On Windows, if the server startup is done with the --defaults-file and --install options, --install must be first.
On Unix, read the above line in option file after the global option file but ensure that it is before the user option file on all platforms before the login path file.
It helps read the options from the named login path in the .mylogin.cnf login path file. A ‘login path’ is an option group that contains options which specifies the correct MySQL server that has to be connected to and which account has to be authenticated as.
To create or modify a login path file, the mysql_config_editor utility has to be used.
By default, the mysql client reads the [client] and [mysql] option groups. For the above command, mysql reads [client] and [mysql] from other option files, and [client], [mysql], and [mypath] will read from the login path file.
Client programs read the login path file even if the --no-defaults option is used. To specify an alternate login path file name, the MYSQL_TEST_LOGIN_FILE environment variable has to be set.
It prints the program name and all options which it gets from option files. Password values are masked.
- Using Options on the Command Line for MySQL programs?
- Python Parser for command line options
- Factors that affect the value of a stock options contract
- C-style parser for command line options in Python
- The MySQL Command-Line Client
- MySQL Option Defaults, Options Expecting Values, and the = Sign
- Command Options for Connecting to the MySQL Server
- Connecting to the MySQL Server Using Command Options
- MySQL command line client for Windows?
- What are some frequently used mysqlimport options while uploading the data into MySQL table through command line?
- Connect to MySQL database from command line
- Command Line Interpreters
- How to read a file from command line using Python?
- File Handling in C#
- Connecting to MySQL database from the command line?