Database Reference
In-Depth Information
Entering SQL Commands
This chapter explains how we can enter our own SQL commands (queries) into
phpMyAdmin, and how we can keep a history of those queries.
The SQL query box
phpMyAdmin allows us to accomplish many database operations via its graphical
interface. However, there will be times when we have to rely on SQL query input to
achieve complex operations. Here are some examples of complex queries:
SELECT department, AVG(salary) FROM employees GROUP BY department
HAVING years_experience > 10;
SELECT FROM_DAYS(TO_DAYS(CURDATE()) +30);
To enter such queries, the query box is available from a number of places within
phpMyAdmin.
The Database view
We encounter our first query box when going to the SQL menu available in the
Database view.
Search WWH ::




Custom Search