Set the active database for subsequent statements.
Section: mysql client basics
Select a database
sql
sql
USE app_db;Explanation
After `USE`, unqualified table names resolve inside that schema.
Learn the surrounding workflow
Compare similar commands or jump into common fixes when this command is part of a bigger troubleshooting path.
Related commands
Same sheet · prioritizing mysql client basics
Connect directly to a database
Open mysql and select the target schema immediately.
Connect to a remote host and port
Specify the host, port, user, and prompt for a password.
List tables in the current database
Display tables in the selected schema.