Back to subject
MySQL/MySQL Workbench & CLI

Read a Query the Way a Client Runs It

Practical lesson

Whether you type this in Workbench, phpMyAdmin, or the plain CLI, the actual SQL and its result are identical the client is just the window you type it into.

SELECT "connected" AS status; is sent to the server exactly the same way in every tool. This is worth remembering: SQL itself isn't tied to any particular program, which is why the skill transfers completely between different tools and jobs.

In a GUI, you'd typically type this into a query editor pane and press a "run" (▶) button or Ctrl+Enter. In the CLI, you'd type it at the mysql> prompt and press Enter.

Either way, the result comes back as the same small table: one column (status), one row (connected). Get comfortable with the idea that the tool is just a delivery mechanism the query and its result are the real subject of this entire course.

Try it yourself
Code

Starter example

Code
SELECT "connected" AS status;
Live preview
+-----------+
| status    |
+-----------+
| connected |
+-----------+
1 row in set