Executing custom SQL commands
Webmin provides a simple interface to your MySQL database server that allows you to execute arbitrary SQL commands. This can be a useful feature when you want to quickly find something in a database or perform a bulk update of multiple rows of data.
How to do it...
Follow these steps to execute an SQL command on your database:
Navigate to Servers | MySQL Database Server.
Click the icon that represents the database you would like to use, for instance,
mysql
.Click the Execute SQL button.
Enter an SQL command in the text area, for instance:
SELECT host,user FROM user;
Click the Execute button.
You will be presented with a sortable display of data returned by the SELECT
command.
How it works...
Webmin simply passes the SQL command to the database server. If the command returns an error, it will be displayed on screen. If the command returns rows of data, Webmin will convert them into an HTML page and display them on screen. Please note that Webmin is running as the root...